WE'VE FOUND SAPhelpdesk!!!

***** Read the Reviews / Rate the Solution
We're not quite there yet.But we're getting there!-and we really want you to know when we're ready.
We can send the latest updates to ur email.Just subscribe to the email updates below and confirm the confirmation link in your email

Here's how to stay updated:

Enter ur email:

OK CODE IN BASIS

What is an OK code?
An OK Code is used by a program to
execute a function for example after a
pushbutton has been clicked

ok_code acts just as a temporary variable that stores the value of sy-ucomm.
When user interacts with the screen elements, the function code that you have assigned is filled in the sy-ucomm field which is turn gets reflected in OK_CODE.

In your ABAP programs, you should work with the OK_CODE field instead of SY-UCOMM. There are two reasons for this: Firstly, the ABAP program has full control over fields declared within it, and secondly, you should never change the value of an ABAP system field. However, you should also always initialize the OK_CODE field in an ABAP program for the following reason:

In the same way that the OK_CODE field in the ABAP program and the system field SY-UCOMM receive the contents of the corresponding screen fields in the PAI event, their contents are also assigned to the OK_CODE screen field and system field SYST-UCOMM in the PBO event. Therefore, you must clear the OK_CODE field in the ABAP program to ensure that the function code of a screen is not already filled in the PBO event with an unwanted value. This is particularly important when the next PAI event can be triggered with an empty function code (for example, using ENTER). Empty function codes do not affect SY-UCOMM or the OK_CODE field, and consequently, the old field contents are transported.




Confused? Feel free to ask

saphelpdesk.co.inYour feedback is always appreciated.I will try to reply Ur queries as soon as time allows.
Regards,
SAPhelpdesk

0 comments:

Post a Comment

Your Ad Here
Write 4 Us ( Support me ) !!!