HasItem Function

The HasItem function is used in the Logic Editor to determine if a Collection of Strings contains a specific String.

Example

In this example, we will check to see if a specific Map Container is available in Runtime. If so, we will open a specific Map in it.

  1. We will add a new Workflow and set it's Trigger.
  2. Drag and drop a Logic block into the work area, and connect it to the Start block.
  3. Double click the Logic block to open the Logic Editor.
  4. Click the HasItem function button.
  5. Click the String Collection link to open the Collection Browser.
    1. Select the Navigation Object, then it's Available Map Containers by ID Property.
    2. Click OK.
  6. Click the String link, and enter the ID of the Map Container. Click OK. This will make the function check the list of Available Map Containers for a Map with this ID.
  7. Drag and drop an Action block into the work area. Connect it to the True exit path for the Logic block, then to the Stop block.
  8. Double-click the Action block to set it's Action.
    1. Select the Navigation Object.
    2. Select Navigate To (Map).
    3. Click the Map link and select the Map to be navigated to.
    4. Click OK.