Liquid UI - WS Reference Library

Add a column into SAP table


Runs On

  SAP GUI Android iOS WM Web
Direct Connect          
Liquid UI Server Connect


This example shows how to create a Liquid UI column in a SAP Table.

User Interface

Log into SAP and navigate to VA03.
Enter a sales order and continue to the next screen.

The table will display a Liquid UI column labeled Volume, displaying the volume for each item.

The volume values are pulled from each item’s data in the Shipping Tab.

Liquid UI Script


if(_transaction == "VA03")
 onUIEvents["/n*"] = {"process":va03ClearVar};
 column("Volume", {"table":"All items","size":12,"name":"z_volume","position":4,"readonly":true});
     if(z_run_function == undefined)
     z_run_function = true;
// This function is responsible for retrieving the Volume of each item
function va03FetchVolume(){
    onscreen 'SAPMV45A.4001'
       // Table Scroll through each Item
        absrow = 1;
        relrow = 1;
 // Fetch the table attributes
  gettableattribute("T[All items]",{"firstvisiblerow":"FVisRow","lastvisiblerow":"LVisRow","lastrow":"LastRow"});
// Scroll to the absolute row
 enter("/ScrollToLine=&V[absrow]", {"table":"T[All items]"});
 onscreen 'SAPMV45A.4001'
 // Refetch table attributes, in case they might of changed
 gettableattribute("T[All items]",{"firstvisiblerow":"FVisRow","lastvisiblerow":"LVisRow","lastrow":"LastRow"});
 // Reset the relevant row
 relrow = 1; // reset the relative row with a new screen
     // end of the screen?
        goto new_screen;
            // end of the table?
            goto end_of_table;
        // Set the cursor on the row
        setcursor("cell[All items,1,&V[relrow]]");
        // Go into Item Data
        onscreen 'SAPMV45A.4003'
        // Navigate to the second tab
     onscreen 'SAPMV45A.4003'
        // Set the Volume to our Liquid UI Column
        // Go back to Overview Screen
        onscreen 'SAPMV45A.4001'
        // Increment out counters
        goto new_row;
        // Scroll back to the top of the table
        enter("/ScrollToLine=1",{"table":"T[All items]"});
// This function is responsible for clearing all the variables
function va03ClearVar()
    // set the column values to a blank string
    // set the function flag to undefined
    z_run_function = void 0;
// This is a trim function for strings that will return the original string with
String.prototype.trim = function()
    return this.replace(/^\s+|\s+$/g,"");


Was this information helpful? Send Feedback