Author Topic: LiquidUI: The "using" Option  (Read 4447 times)

chirag.amin@guixt.com

  • GuiXT Forum
  • Newbie
  • *
  • Posts: 34
    • View Profile
LiquidUI: The "using" Option
« on: February 12, 2016, 12:05:21 PM »
The "using" option is very useful when calling processes. It allows variables to be passed to functions. In this example, we will have an input field for the user to enter a name. When then click on the pushbutton, the name will be displayed in a message to the screen.

LiquidUI code:

//////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Author: Synactive, Inc. [1065 E. Hillsdale Blvd, Foster City, CA, 94404, USA]
// Email: support@guixt.com; sales@guixt.com;
// Contact: 650.341.3310
// Version: 1.0.0.0
//////////////////////////////////////////////////////////////////////////////////////////////////////////////

// Clear the screen
clearscreen();

// Create an inputfield to retrieve the name of the User
inputfield([0,0], "Your Name:", [0,12], {"size":20,"name":"z_name"});


// a button to run the function to display the message
// use "using" to pass the variable for the name
pushbutton([0,35], "Enter", {"process":displayMessage, "using":{"name":"&V[z_name]"}});

// function displays the welcome message
function displayMessage(param){
   message("S:Welcome to the Easy Access Screen, "+param.name+"!")
}