Skip to main content

Using Lookup List function to return rows of values

Select several machine records with Lookup List and map each selection into a row of an approval form's sub-list.

Note

Lookup List lets users select several source records and fill a row in an associated sub-list for each selection.

This example selects machines from a data list and copies their type, name, model, and active service date into approval-form detail rows. Match each source field to a target column with a compatible data type.

See the Lookup List field guide. For one selected record that fills several individual form fields, use Lookup. Open the target form through the approval form designer.

Step 1. Create or manage a data-list as "source data"

Create or open Machine List in the application. Prepare Status and Type option fields, Name and Model text fields, and an Active service date date field. For the test below, prepare at least three Active records and one record with another status.

Please Note: If you will filter by Status, add that source-list field to the index before configuring the filter.

Step 2. Add associated list in your "target form"

In the approval form designer, add a SubList called Machine details. The original example calls this control List. Prepare target columns for Type, Name, Model, and Active service date, matching the source field types. Use a date column for the date value.

The source data list supplies the records. Machine details is the sub-list on the current form that will receive the selected rows; keep those two roles distinct when configuring the binding.

Step 3. Set properties of Lookup List

Add a Lookup List control and configure its properties:

  • Source data Binding: Select the application and Machine List created in Step 1.

  • Appearance:

    1. Set Max Selection to the number of records users may select. For a small test, use 2.

    2. Set the required Display Field to a recognizable source value, such as Name.

    3. Open Additional Fields. Use the checkboxes to choose the columns shown in the picker. Select Machine details as the Associated list, then map each source field to its target Associated field: Type to Type, Name to Name, Model to Model, and Active service date to the date column. Displaying a column in the picker and mapping a value into a form row serve different purposes.

    4. Under Filters, add Status equals Active if only active machines should be selectable.

  • Validation: Set required or custom validation rules as needed. If an action should run when the selection changes, configure the control's Value Changed action as described in the Lookup List field guide.

Historical Lookup List Appearance settings showing Max Selection, Display Field, Additional Fields, and Filters.

The original settings crop uses example values 10 and Id. For the test above, use 2 and Name. The screenshot's product build and capture date are unknown.

Step 4. Manage the layout and publish

Preview the form and select the Lookup List search button to open the picker. Confirm that it offers the intended active machines and displays the chosen columns. Select two records, confirm the selection, and inspect the generated detail rows.

Check the selection limit and the results of changing or clearing a selection. Save the design, publish when ready, and submit and reopen a test request to verify that its detail values were saved.

Example Demo

Selecting two machines should produce two rows in Machine details. Compare each row's type, name, model, and date with its own source record. If the names are correct but another column is blank or incorrect, check that column's mapping and data type in Additional Fields.

Furthermore

Use the associated sub-list's property-value expressions or calculated fields for per-row calculations. For example, derive a value from each machine's active service date, then compare rows with different dates to check the result.

Use Lookup List for multiple selected records and detail rows. Use Lookup when one selected record should populate individual form fields.

Did this answer your question?