Button

Buttons are used extensively in Apps.

Key points and properties:

  • Visibility. Whether the button is visible to the user. You might want to include hidden buttons that are triggered via scripting.
  • Hotkey. A keyboard trigger for the button.
  • Icon. Select an icon or use font-awesome shortcuts. If you type in the name, omit the fa- prefix.
  • Action. What happens when the user clicks the button. Additional properties are added based on the selected action.
    • None. Use this, if the button's functionality is to be provided by scripting and no other action is required.
    • Move Page. Move to a named page in a multi-page App.
    • Pop Up. Display a page in a popup, or a popup Container object.
    • Login. Use this on the App's login page.
    • Logout. This logs the user out, and directs them to the App's Login page.
    • XML Request. This action executes a Pierbridge XML request. Click to select the request, and then create the mapping. See XML Requests for more details on mapping. When an XML Request button is selected on the canvas, any fields associated with that request display the icon and the button itself, the icon. The tooltips for icons show the mapping.
    • Weigh. This action gathers a weight from a connected scale. Click to map the following parameters:
      • WeightMajor and WeightMinor. The controls that hold the item’s major weight and minor weight respectively (for example, pounds and ounces).
      • Height, Width and Length. Controls that provide the item’s dimensions.
    • Procedure. This action lets you execute a stored procedure. Set Source Name and Procedure. Then, provided Composer Designer can resolve this, click to configure.
    • Data Engine Modify. This action lets you perform a database modify Operation (Insert or Update) on a Target control that is mapped to a database column. The Target control must be a Textbox with its Action property set to Data Engine Lookup which will mean it specifies the table and column to be targeted. If you try and set Target to anything else, Composer Designer will give you a warning.
  • Scripting events: onClick, XMLRequest and XMLResponse.
Tip

If you see a button with Action of None, it is very likely that that button is used in scripting. In the Warehouse App, the button object next to the Carrier Service snippet is one example of this. The advanced options provided by this button are done in scripting. To see this, note the button's Name, click the page so that the page is selected. In the Scripting window, you will see the page level scripting (if the button is still selected, you will only see scripting directly associated with the button (which is none in this example). You can then search the script for the button's Name, and see the relevant JavaScript.

Article last edited 9 February 2017