Application Development 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: 

Dialog Screen and WRITE.

Former Member
0 Kudos

Hi,

I have create an ABAP program.. which CALL SCREEN 100. This screen 100 is design using Graphical Screen Painter. I have create an push button on it. When the button is press, I try to do some logic behind and want to do a WRITE statement but somehow.. the screen never print out the WRITE statement. Is there anyway to do it?

Regards,

Rayden

1 ACCEPTED SOLUTION

Former Member
0 Kudos

You can't use write statement in Dialog programs..eventhough if you want to use then use below syntax :

case sy-ucomm.

when 'PUSH'.

<b>leave to list-processing</b> . " If it is not working then try <b>leave list-processing.</b>

write:/ 'Push is selected'.

endcase.

Thanks

Seshu

3 REPLIES 3

former_member223537
Active Contributor
0 Kudos

Hi,

WRITE statement wont work on screen painter.

Create a LABEL i.e. a TEXT FIELD and assign a name to it say 'RESULT' in Screen Layout.

Acitvate the screen.

In the PAI, when Push button is pressed

CASE l_OKCODE.

WHEN 'HIT'.

v_flag = 'X'.

ENDCASE.

In the PBO, when Push button is pressed.

IF V_FLAG = 'X'.

LOOP AT SCREEN.

if SCREEN-NAME = 'RESULT'.

RESULT = 'Hit button pressed'.

ENDIF.

ENDLOOP.

else.

clear RESULT.

endif.

gopi_narendra
Active Contributor
0 Kudos

Check the sample program <b>demo_dynpro_push_button</b>

Regards

Gopi

Former Member
0 Kudos

You can't use write statement in Dialog programs..eventhough if you want to use then use below syntax :

case sy-ucomm.

when 'PUSH'.

<b>leave to list-processing</b> . " If it is not working then try <b>leave list-processing.</b>

write:/ 'Push is selected'.

endcase.

Thanks

Seshu