Liquid UI - WS Reference Library

Assign values to screen elements


Purpose

The following scenarios demonstrate the usage of set() command:


User Interface

 

  • Assigning values to screen elements:

 You can assign values to the elements on the Sales Order screen (VA01) using set command, as shown below:


 

//SAPMV45A.E0101.sjs

 set("F[Order Type]","OR");
 set("F[Sales organization]","1000");
 set("F[Distribution Channel]","10");
 set("F[Division]","00");       

 

  • Setting default radiobutton and checkbox

You can pre-select the checkbox and radiobutton in Goods Receipt screen(MB01) from VA01 screen, as shown below:


 

 

Steps:

  1. Goto Create Sales Order screen (VA01).
  2. Enter the Liquid UI Script in the SAPMV45A.E0101.sjs Script File.

Note: Do not select Print checkbox. The checkbox is selected using set() command.



Liquid UI Script

//SAPMV45A.E0101

checkbox([4,25],"Print",{"name":"z_print"});
del("F[Order Type]",{"triple":true});
del("G[Organizational Data]");
del("P[Create with Reference]");
del("P[Sales]");
del("P[Item overview]");
del("P[Ordering party]");
pushbutton([TOOLBAR],"Movement Type","/nmb1c",{"process":z_test});
radiobutton([1,25],"Indvidual Slip",{"name":"z_radio","value":"A"});
radiobutton([2,25],"Collective Slip",{"name":"z_radio","value":"B"});
		function z_test() {
        onscreen 'SAPMM07M.0400'
        if(z_radio=="A") {
          set("R[Individual Slip]","X");
          }
          if(z_radio=="B") {
            set("R[Collective Slip]","X");
          }
        set("C[Print]","X");
        }

Was this information helpful? Send Feedback