How to Pass Parameter Values to Action through Function in Sage X3
Create one window for the testing purpose called “YTEST”. Go to
All Development Script Dictionary
Script Dictionary Actions Action parameters
Click the action parameters as shown below.
The following screen will appear as shown below
Here you can create the new action, which is window entry type and map window, also add a specific process.
Add the parameter, which we have created earlier in the action parameters function.
Once an action has created successfully with parameters, the next step is to provide the action code to function. These parameters will come up in the parameter field automatically based on the action code given in the action code field. We will have to assign the parameter values as input, either they could be hardcoded values or screen field codes like “[M: XYZ] ABCDEF” as shown below.
We need to write the code to display the parameter values through a specific process as shown. The PARAM is the standard variable, which is an array type.
When we provide the parameters in action, the parameter’s values will be automatically stored in the PARAM variable. The PARAM index will start from “1” by default.
After the coding part has completed, execute the function and click on the Ok button in the message window, then the parameter’s values will be displayed as per the code written in the specific process.