Prerequisites
- Products: Liquid UI WS, Liquid UI Server or Local DLL, Client Software
- Commands: onscreen(), load(), set(), pushbutton()
Purpose
This article guides how to pass the values between sessions as a parameter with the "using" option. To demonstrate this process, we are considering the SAP Easy Access screen as an example, and we’ll guide you through the following steps:
- Delete the image container on the SAP Easy Access screen
- Add a toolbar push button to execute the process
- Add a function to load the script file
- Add a function to pass the values
User Interface
//Create the file SAPLSMTR_NAVIGATION.E0100.sjs inside your scripts folder for customizing the SAP Easy Access screen
//Now, let's add the Liquid UI script to the above file and save it
Customization
- Delete the image container on the SAP Easy Access screen using the del command.
//Deletes the image container on the SAP screen del("X[IMAGE_CONTAINER]");
- Add a toolbar push button labeled Pass Values that executes open_new_session process and opens a new session on click.
//Creates a push button that opens a new session pushbutton([TOOLBAR], "Pass Values", "/oiw31",{"process":open_new_session, "using":{"z_order_type":"PM01" }});
//Create esession.sjs file in your scripts folder
//Now, add the below Liquid UI script to the above file and save it - Load the functions_iw31.sjs file.
//loads the file load('functions_iw31.sjs');
Note: When you are passing values between sessions, the function should be loaded in the esession file since we are opening a new session.
//Create functions_iw31.sjs file in your scripts folder
//Now, add the below Liquid UI script to the above file, and save it - Add the open_new_session function to pass the values.
//Function to pass the values function open_new_session(param){
onscreen 'SAPLCOIH.0100'
set('F[Order Type]',param.z_order_type);
enter('?');
}
SAP Process
- Refresh the SAP screen and click the Pass Values toolbar push button. You will observe the values passed to the Order Type input field in a new session, as shown below.