Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

ABAP PROGRAM

Former Member
0 Likes
411

Hi Abapers,

I am new to sap-abap.Got stuck in a small program(hello world program in sap abap documentation and examples).my question is that without any code in PBO or PAI of screen 100,how is the string 'hello world' getting into the screen and when 'next' button is pressed how is the output getting printed??

Regards,

Prashanth.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
384

Hi,

the field name in screen 100 is given as 'INPUT'..which is same as the variable declared of type c and with default value 'Hello world!' in the program..hence the string is getting into screen 100...and when you press the next button,the control is returned to the program from the screen 100 and the code

SKIP TO LINE 10.

POSITION 40.

WRITE input.

plays the role of printing the output.The PBO or PAI doesnt come into act here ..

reward points if helpful

regards,

Goutham.

3 REPLIES 3
Read only

Former Member
0 Likes
385

Hi,

the field name in screen 100 is given as 'INPUT'..which is same as the variable declared of type c and with default value 'Hello world!' in the program..hence the string is getting into screen 100...and when you press the next button,the control is returned to the program from the screen 100 and the code

SKIP TO LINE 10.

POSITION 40.

WRITE input.

plays the role of printing the output.The PBO or PAI doesnt come into act here ..

reward points if helpful

regards,

Goutham.

Read only

Former Member
0 Likes
384

Define label on screen with 'Hello World'...

Will have to think about auto-print..

Regards,

Mohaiyuddin

Read only

Former Member
0 Likes
384

Hi Prashanth,

The program about which you are saying is a help program which is used to understand the basic concepts of ABAP. The program is used to show just how an ABAP program works.

That program is simple. let me tell you how it works.

the variable INPUT stores the value HELOLO WORLD! by default.

now we are calling the screen 100.

so the control takes you to the screen 100. you just double click on the screen 100 the it will show you the screen layout. there you cna see how the screen 100 was created.

but since there is nothing written in the PBO or PAI modules the control will take you back to the report program output screen.

this is how that program works.

any more issues. feel free to ask me.