CHECK_CURRENT_FORM Function
Check that RAMP is showing a screen.
Syntax
CHECK_CURRENT_FORM(sFormName [, sMessageText1] [, sMessageText2] ...)
Parameters
|
Return Value
Boolean. Returns one of the following possible values:
|
Remarks
Used for checking whether the script or user has progressed to a particular screen, or has stopped at an earlier screen.
If the CHECK_CURRENT_FORM returns false, the function will also automatically hide the Current RAMP screen and display the message provided.
If the script wants to test that the expected screen has arrived, and yet still display the current screen if it hasn't, it should not use function CHECK_CURRENT_FORM, but instead use
if (CURRENT_FORM() == "My_Form");
When you are writing scripts that handle validation errors on a screen, you usually want the current screen to be displayed even if a validation error occurred and the user has not progressed to the expected next screen. So in this situation you should not use CHECK_CURRENT_FORM.
Example
if ( !(CHECK_CURRENT_FORM("uItemMasterBrowse","Unable to navigate to form uItemMasterBrowse")) ) return;