‎2009 Oct 23 7:44 AM
Dear Experts,
is there any setting that needs to be done before creating any dialog program.
I m asking so because i m getting an error 'Statement is not accessible' for CALL SCREEN 100.
Regards,
Maverick
‎2009 Oct 23 7:54 AM
Hi,
Are you callling the Screen within TOP INCLUDE ??
All ABAP statements and key words must be with in modules only in Case of Screen Programs.
Form Frmname
endform.
Module mdname.
endmodule
etc
Check your program.
Cheers
Ram
‎2009 Oct 23 7:53 AM
You have posted the same question earlier and that was deleted. Please be more specific when you ask a question. Explain what you have done and where you have called the screen.
‎2009 Oct 23 7:57 AM
Thanks for ur reply.
But i didt not get the answer of the deleted question.
So i tried new program from scratch and getting the same error msg. ' Statement is not accessible'.
i hv written the following code in ABAP Editor
PROGRAM SAPMZ_TEST_DYNPRO.
DATA: input TYPE i,
output TYPE i,
radio1(1) TYPE c, radio2(1) TYPE c, radio3(1) TYPE c,
box1(1) TYPE c, box2(1) TYPE c, box3(1) TYPE c, exit(1) TYPE c.
CALL SCREEN 100.
MODULE init_screen_100 OUTPUT.
CLEAR input.
radio1 = 'X'.
CLEAR: radio2, radio3.
ENDMODULE.
MODULE user_command_0100 INPUT.
output = input.
box1 = radio1.
box2 = radio2.
box3 = radio3.
IF exit NE space.
LEAVE PROGRAM.
ENDIF.
ENDMODULE.
Regards
Maverick
‎2009 Oct 23 7:54 AM
Hi,
Are you callling the Screen within TOP INCLUDE ??
All ABAP statements and key words must be with in modules only in Case of Screen Programs.
Form Frmname
endform.
Module mdname.
endmodule
etc
Check your program.
Cheers
Ram
‎2009 Oct 23 8:01 AM
Thanks for ur reply
Let me tell u how i created my program
first i created a program with SAPMZ_TEST_DYNPRO name in se38.
then i went to se51 and created the program with same name and required attributes and elements.
then i added the code 'posted in previous reply', into abap editor.
when i checked for syntax , i got the error msg 'Statement is not accessible' for CALL SCREEN 100 .
could you guide me where i m mistaking.
Regards
Maverick
‎2009 Oct 23 8:06 AM
Hi Mavirick,
i think you are calling a screen in executable program, if it is the case then use start-of-selection infront of call screen statement.
write like this
start-of-selection
call your screen here
Thanks
Sai
‎2009 Oct 23 8:13 AM
Thanks Ram
you resolved my problem.
actually I m learning Dialog Programming by my own so getting little probs.
Thanks again.
Regards
Maverick
‎2009 Oct 23 8:19 AM
Hi,
Firstly you have to create the program of type "Modulepool" in SE38 and not "Executable".
Add START-OF-SELECTION before calling the screen
DATA: input TYPE i,
output TYPE i,
radio1(1) TYPE c, radio2(1) TYPE c, radio3(1) TYPE c,
box1(1) TYPE c, box2(1) TYPE c, box3(1) TYPE c, exit(1) TYPE c.
START-OF-SELECTION. <--------------------
CALL SCREEN 1000.
MODULE init_screen_1000 OUTPUT.
CLEAR input.
radio1 = 'X'.
CLEAR: radio2, radio3.
ENDMODULE.
MODULE user_command_1000 INPUT.
output = input.
box1 = radio1.
box2 = radio2.
box3 = radio3.
IF exit NE space.
LEAVE PROGRAM.
ENDIF.
ENDMODULE.Now the program will be activated. To eecute the program you need to create a transaction as modulepool programs cannot be executed directly.
Hope it solves your problem.
Thanks,
Sri.
‎2009 Oct 23 8:20 AM
Hi,
Open the Program in SE80 or if you are in SE30 then go to DISPLAY OBJECT LIST by pressing ctrl + shift + F5
Now activate here, if you still face the problem, recreate the Screen in SE80, and activate.
Try changing the program attribute from 1 to M
Cheers
Ram
‎2013 Sep 14 6:58 PM