2006 Dec 11 7:04 AM
how many okcode u can create in modulepool and how to clear okcode?
2006 Dec 11 7:37 AM
Hi
In case of dialog programs , each screen has an okcode field associated with it.
okcode captures the user command on PAI .
plz take a look at the code below for further clarification :
Data : ok_code type sy-ucomm.
" in the PAI module MODULE_USER_COMMAND for screen XXX
module module_user_command .
ok_code = sy-ucomm.
CASE ok_code.
WHEN ' ' .
" write the code for the operation to b performed
WHEN ' ' .
" write code 2 for another command
ENDCASE.
endmodule.
use CLEAR ok_code to clear the value of ok_code.
One screen in a module pool program can have a maximum of 1 okcode.
In the same lines , a module pool program can have as many okcode as the number of screens in it.
i hope it helps u..in case of further queries plz revert.
Regards
Pankaj
for eve3ry screen you can create one ok code you can clear it by saying clear okcode. for example like this
data:okcode_100(5) type c.
case okcode_100.
when 'BACK'.
clear okcode.
.............
................
endcase.
Regards,
Manohar.
2006 Dec 11 7:07 AM
HI,
okcode contains the user command so there can be only one okcode.
CLEAR: okcode.
REgards,
2006 Dec 11 7:07 AM
for every normal screen u can have one okcode.
we cant have okcode for subscreen.
get the okcode in a variable & clear it.
Eg.
Data : okcode type sy-ucomm,
save_ok like okcode.
Module_user_command.
save_ok = okcode.
clear okcode.
case save_ok.
..
endcase.
2006 Dec 11 7:09 AM
for eve3ry screen you can create one ok code you can clear it by saying clear okcode. for example like this
data:okcode_100(5) type c.
case okcode_100.
when 'BACK'.
clear okcode.
.............
................
endcase.
Regards,
Manohar.
2006 Dec 11 7:37 AM
Hi
In case of dialog programs , each screen has an okcode field associated with it.
okcode captures the user command on PAI .
plz take a look at the code below for further clarification :
Data : ok_code type sy-ucomm.
" in the PAI module MODULE_USER_COMMAND for screen XXX
module module_user_command .
ok_code = sy-ucomm.
CASE ok_code.
WHEN ' ' .
" write the code for the operation to b performed
WHEN ' ' .
" write code 2 for another command
ENDCASE.
endmodule.
use CLEAR ok_code to clear the value of ok_code.
One screen in a module pool program can have a maximum of 1 okcode.
In the same lines , a module pool program can have as many okcode as the number of screens in it.
i hope it helps u..in case of further queries plz revert.
Regards
Pankaj
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |