Show TOC

Syntax documentationset_new_ok_code Locate this document in the navigation structure

You may only use this method in the handler method of a system event. It sets an OK_CODE that triggers PAI processing. This means that data is transferred from the screen to the program, and you can take control of the program in your PAI modules.

Syntax Syntax

  1. CALL METHOD cl_gui_cfw=>set_new_ok_code
    	EXPORTING new_code	= new_code
    	IMPORTING rc		= rc.
End of the code.

Parameters

Description

new_code

Function code that you want to place in the OK_CODE field (SY-UCOMM).

return_code

  • cl_gui_cfw=>rc_posted: The OK_CODE was set successfully and the automatic field checks and PAI will be triggered after the event handler method has finished.

  • cl_gui_cfw=>rc_wrong_state: The method was not called from the handler method of a system event.

  • cl_gui_cfw=>rc_invalid: The OK_CODE that you set is invalid.