Anywhere Mobility Studio Documentation

Button Properties

Property Description
Process Code Identifier of the process
Activity Code Identifier of the activity
Code Identifier for the button
Type <none>, Back, Cancel, Lookup, LookupOK, Repeat. The type decides which action will be performed
Description Caption of the button on the mobile client
Hotkey Function button which activates the button as an alternative to clicking or touching
Default Indicates the button that will be activated when a user pushes enter
Connection No. When pressing the button, a connection is triggered to be executed Which will write data to the database
Codeunit No. Determines that a Codeunit should be executed. This will be done after the connection has been processed
Skip Validation In tandem with the control’s mandatory property, the skip validation allows to skip mandatory fields to access a different part in the flow

Type

The type of a button decides what step will be activated in the flow:

  • <none>
    This is the default type. A button with this type executes the next step in the flow.
  • Back
    Takes the process back one or more steps in the activity stack. Also deletes the activity step and stack parameters associated with these steps. Connection and Codeunit will not be executed.
  • Cancel
    Takes the process back until the beginning of the current activity. Deletes the activity Parameters. Connection and Codeunit will not be executed.
  • Lookup
    Activates a lookup for the parameter linked to an active editable textbox. A lookup is a data grid activity with records from the same table as the table of the parameter. After the lookup, the parameter is filled with the selected value.
  • LookupOK
    Basically the same as a Lookup, with the added functionality that it will execute the default action on the activity where the lookupok button is defined. Including the connection and Codeunit defined on the default button.
  • Repeat
    This button requires a connection. This button will, when there is no valid process flow, return to the same activity, and will clear all related stack parameters. This allows a recurring activity to be configured.

Codeunit No.
Executing a Codeunit makes it possible to perform more complex tasks than modifying records in the database, like releasing an order or printing a document. The Codeunit no. is a Codeunit that can be called by clicking a button in the mobile client. The Codeunit is executed after input has been validated, the connection is triggered but before the next step in the process is determined. The Codeunit will always be called synchronised, while the post-processing in the connection will always be run through the Job Queue.

The Codeunit´s “OnRun” trigger is called. The Codeunit´s “OnRun” trigger should take the NDAW Queue record as parameter. This Queue record contains key information about the state the process is currently in. From the Codeunit triggers in standard Dynamic NAV Codeunits can be called.
Most Pre-configured processes use the Post Processing via the Connection that will execute the Codeunit from the Job Queue.

NOTE

This functionality should only be used when post processing with the Job Queue in the Connection is not possible/desired.