If your map contains feature layers (hosted feature layers, hosted feature layer views, hosted table layers, subtype group layers, or ArcGIS Server feature layers), you can define forms that editors can use when they update field values for the feature layers in the web map. You can define a form for every feature layer in the map or only those layers that you know the users of the map will need to edit.
Tip:If you own the feature layer that is in the map or you are an organization administrator, you can configure forms for the feature layer before you enable editing on the layer.
When you configure a form, you specify what form elements the form contains and how the elements appear. Having a form helps guide editors to the correct fields and allowable attribute values for each editable field.
The form can be saved as part of the map or the layer. When you share the map or layer, others can use the forms you define to edit the feature layers or related records in the map. To learn more, see Save the form.
Currently, you can configure forms in Map Viewer in ArcGIS Online and ArcGIS Enterprise and in Field Maps Designer.
Before configuring a formBefore you configure a form for a feature layer in your map, familiarize yourself with the layer's contents and field settings. What a field contains affects whether you create element groups for fields. The settings that are applied to a field—such as whether null values are allowed, whether a default value is defined, and whether the layer owner defined lists for the field—affect how you format the field elements on the form.
Configure a formYou can configure an input form for each feature layer in the map. You define what fields (elements) appear on the form and where they are placed.
When an editor selects a feature in an editable feature layer, the form appears so the editor can input attribute values for that layer.
Follow these steps to configure a form for a feature layer:
The Configure form window appears.
Form elements are field groupings and the input fields that appear on the form. Field elements are based on existing fields in the feature layer.
If you close the map without saving, you lose the form.
If you need to change the form, repeat the steps above. Be sure to save the form after you edit it.
Convert the existing pop-upIf the feature layer has pop-ups configured, click Convert pop-up to add fields from the pop-up to the form canvas.
Fields that are not part of the pop-up configuration appear in the Fields list in Form builder. You can drag them onto the form canvas to add them as elements to the form, as described in the next section.
After you add fields as elements to the form, you can create groups to aggregate related fields or proceed with formatting field elements.
Fields that contain high-accuracy GPS metadata are unable to be added to the form.
Add descriptive textYou can add descriptive text to the form to provide contextual information or additional details about form elements. Descriptive text is read-only and cannot be altered by form editors.
Follow these steps to add a descriptive text element to the form:
The Properties pane appears, allowing you to edit the descriptive text element.
Choose which fields in the layer to present to editors as form elements. In most cases, you add fields that the editors will use to update values.
For example, if the feature layer contains the following fields—Site Name, Site Type, Build Status, Landscaping, Edit Date, Editor Name, Creation Date, Creator Name, ID, and Shape—you might place only the Site Name, Site Type, Build Status, and Landscaping fields on the form because the Edit Date, Editor Name, Creation Date, Creator Name, and ID fields are automatically populated, and the Shape field is populated when editors add a feature to the layer.
You can also add fields for reference and disable editing on the form element. In the previous example, you might include the Edit Date field as an uneditable element on the form so the editors can see when the feature was last updated.
If the layer or table contains a large number of fields, you can use the Find Fields search bar in the Fields list to locate a specific field.
If you created a relationship class in the geodatabase in ArcGIS Pro before publishing a hosted feature layer, if the hosted feature layer was created using a template that includes a relationship class, or the hosted feature layer was created for a form containing a repeated section in ArcGIS Survey123 Connect, you can add a related record element to the form. This allows users to view and add related records associated with the hosted feature layer, such as a table, while filling in the form.
For example, on a form used to monitor urban tree health, a related table can include inspections of each tree. By adding a related record element to the form, you can add a new inspection to the related table while editing attributes for the tree feature.
Follow these steps to add a related record element to the form:
The related record element is added to the form canvas.
To group related fields in the same physical location on the form, create a group element. Grouping elements is similar to placing questions in the same section on a paper form. Groups on digital forms have the added advantage that they can be contracted to show only the group heading until the form user expands the group.
For example, on a form to update content in a trails feature layer, create a group for all the fields related to trail properties, such as the trail name, type, and difficulty. You can create a separate group for the fields that record trail maintenance information, such as maintenance crew name, the date maintenance was last performed, and the description of the maintenance performed. If you choose to open the form with groups collapsed, the editors see only the two group names until they expand the groups.
Follow these steps to group related elements together on the form in a collapsable section:
A form element is added to the form canvas.
You can drag fields from the Fields list in the Form builder panel or from the form canvas.
The Properties pane appears, allowing you to edit the following information:
You can remove all form elements from a group by selecting Ungroup from the group toolbar. You can remove multiple elements from the group by pressing Ctrl, selecting each element you want to remove, and dragging them out of the group.
Add contingent field groups to the formIf the data owner created contingent field groups in ArcGIS Pro for the data, the contingent field groups appear in the Field groups list next to the form canvas.
Because the fields are related—the values of one field determine or limit what values you can set for the other fields—the contingent fields are added to the form in a group element when you add them from the Field groups list. Contingent fields should stay grouped together so editors can fill them out subsequently in Map Viewer. If you remove a field from its field group, a warning displays.
Contingent field groups that share one or more fields are listed together. They are added to the form as one field group.
Field groups that you must add to the form appear in the Required section of the list. Field groups are required if they were configured as restrictive in ArcGIS Pro, which means the attribute values that editors provide when editing the fields in this field group must comply with the contingent value definitions.
Caution:If you do not add required contingent field groups to the form canvas, editors cannot use the form to edit the feature layer.
To learn how to create contingent field groups in ArcGIS Pro, see Create and manage contingent values.
Follow these steps to add contingent value field groups to the form:
If the layer or table contains a large number of field groups, you can use the Find field groups search bar in the Field groups list to locate a specific field group.
When you select a form element on the form canvas, the Properties pane appears.
The previous section described setting properties for group elements.
For field elements, the Formatting section of the Properties pane shows properties that you can define for the element on the form and those that are inherited from the layer and cannot be altered for the form. The following sections describe the properties you can define for field elements on the form.
Define a display nameEvery form element requires a value for the Display name setting. The display name is the label that accompanies the element on the form.
For fields, the default display name is the same as the field name. Accept the default or type a more user-friendly or descriptive display name for each field.
Format text elementsIf a form element references a string field, follow these steps to format the element:
For example, you could type Type the applicant's first name as placeholder text for a field that stores the first name of the person applying for a loan.
Placeholder text appears inside the input field element and is replaced by the text the editor provides.
You cannot set placeholder text for a field that has a default value defined.
The description appears below the element on the form.
Sometimes, a feature layer is published with a default text field size rather than a length that makes sense for the field. For example, a field that can have only a finite number of values, such as yes, no, or unknown, might have a field length in the feature layer of 256 characters. But you can set a minimum and maximum of 1 if you want editors to type only y, n, or u when editing values in the field.
You cannot set a maximum character length that is longer than the field length.
See Define elements as required for more information.
For example, you include a field for reference purposes, but you don't want editors to alter the values in the field.
Follow these steps to format elements that reference date and time fields:
The description appears below the element on the form.
Seconds can be stored in the field, though they will not display in ArcGIS Online.
For example, for a date field in a new layer that records inspections that will be completed in the first quarter of the year, set the start date to the first day of the year and the end date to March 31 for the appropriate year.
For example, for forms that are used during business hours only, you can restrict the start and end times so they do not fall outside your business hours.
See Define elements as required for more information.
For example, you include a field for reference purposes, but you don't want editors to alter the values in the field.
If the element uses a feature layer field that is a double, an integer, or a big integer data type, follow these steps to format the form element:
For example, you could type Type the applicant's first name as placeholder text for a field that stores the first name of the person applying for a loan.
Placeholder text appears inside the input field element and is replaced by the text the editor provides.
You cannot set placeholder text for a field that has a default value defined.
The description appears below the element on the form.
See Define elements as required for more information.
For example, you include a field for reference purposes, but you don't want editors to alter the values in the field.
If the field in the feature layer has a list defined for it that contains three or more values, you can configure the form element to appear as a combo box or option buttons.
If the list contains a lot of values (for example, seven or more values), a combo box saves space on the form.
The description appears below the element on the form.
See Define elements as required for more information.
If the form element is not editable, the button or list option setting on the form shows the existing value for the attribute. If you add a feature, no value shows for the combo box or button elements unless the field has a default value defined.
If the field in the feature layer has a list defined for it that contains only two possible values, and the field has a default value set in the layer, you can define that element to appear as a toggle switch on the form or appear as a combo box or buttons.
If the field in the layer does not have a default value set, you can configure the element to appear as a combo box or buttons on the form.
You can change which value equates to an enabled switch by clicking the Switch order of values button next to the switch values.
If the field does not have a default value set and you choose Switch for the input type, the element displays as a combo box on the form.
The description appears below the element on the form.
See Define elements as required for more information.
If the form element is not editable, the button, list option, or toggle switch setting on the form shows the existing value for the attribute. If you add a feature, no value shows for the combo box or button elements. For switch elements, the default setting is displayed on the form.
You can customize how related record elements appear in the form by formatting their description, sort order, and the number that can be previewed. Follow these steps to format related record elements:
The description appears below the element on the form.
If you sort by a string, double, or integer field, you can sort by ascending or descending value. If you sort by a date field, you can sort by the most recent or least recent value.
Choosing a value greater than three may require additional scrolling on the form and is not recommended.
You can create a separate form for the related table, and choose which fields from the related table to display and how to format them.
Define elements as requiredTo enforce the input of data for a field, you can configure form elements so that they require an entry. For example, if all applications require a submission date, configure the submission date element to be required.
When editors use the form, they see an asterisk next to the fields that require input, and they cannot save their edits until a value is provided.
A * Required chip appears on the form element, indicating that editors must supply a value for this field.
You can make the form dynamic based on the following logical conditions that you define using the ArcGIS Arcade expressions:
Once defined, you can reuse expressions for other form elements.
Configure conditional visibilityYou can conditionally show or hide form elements based on values added to previous fields. For example, a Building Assessment form includes a field to indicate whether there is water damage. It also includes a group form element containing fields related to water damage. A conditional visibility expression can be applied to the water damage group so it only appears if water damage is indicated in the earlier field. To create a conditional visibility expression, complete the following steps:
The Expressions pop-up appears, displaying expressions previously created for the form.
The Expression builder window appears. The builder allows you to write and preview an expression in Arcade before saving it to the selected form element.
For example, if a water damage group element only needs to appear if water damage was indicated in an earlier field, the following condition can be used to build the expression:
Here is what the same expression looks like in Arcade syntax:
DomainName($feature, "water_damage") == "Yes"
Map Viewer applies the Arcade Form Constraint profile to evaluate whether a feature meets the criteria defined in the expression. If a value other than Yes is indicated in the water_damage field, the water damage group will not appear in the form.
A </> Visibility chip appears on the form element, indicating that the conditional visibility expression has been applied to the group or field.
Now that you created the expression, you can apply it to any form element. You can see which elements are using the expression by clicking the number next to the expression in the Expressions pop-up. See Reuse expressions to learn more.
You can duplicate, edit, or delete the expression at any time from the Conditional Visibility menu. To edit the expression using Arcade, click Edit Arcade from this menu.
Configure conditionally required elementsYou can conditionally require form elements based on previous values entered in the form. For example, a debris description field should only be required if the length of the storm debris is greater than 3 meters.
The Expressions pop-up appears, displaying expressions previously created for the form.
The Expression builder window appears. The builder allows you to write an expression and preview it in Arcade before saving it to the selected field or group.
Each expression is defined by one or more conditions. A condition includes a field name, an operator, and potentially, a value. The list of available operators is determined by the type of field (string, number, or date).
For example, if a debris description field only needs to be required if the debris is greater than 3 meters, the following condition can be used to build the expression:
The following is the same expression in Arcade syntax:
($feature, "debris_length") > 3
To create more complex expressions, click Launch Arcade editor.
When you apply multiple conditions to the same element, you can choose whether all conditions must be true or only one condition must be true for the form element to be required.
ArcGIS Online applies the Arcade Form Constraint profile to evaluate whether a feature meets the criteria defined in the expression. If a value less than 3 is entered in the debris length field, the debris description field will not be required in the form.
A </> Required chip appears on the form element, indicating that the required expression has been applied.
Now that you created the expression, you can apply it to any form element. You can see which elements are using the expression by clicking the number next to the expression in the Expressions pop-up. See Reuse expressions to learn more.
You can duplicate, edit, or delete the expression at any time using the overflow menu in the Expressions pop-up. To edit the expression using Arcade, click Edit Arcade from this menu.
Configure conditional editingYou can conditionally enable editing for form elements based on previous values entered in the form. For example, editors should only edit values in a date_pipe_replaced field if the value for the pipe_replaced field value is set to yes.
The Expressions pop-up appears, displaying expressions previously created for the form.
The Expression builder window appears. The builder allows you to write an expression and preview it in Arcade before saving it to the selected field or group.
Each expression is defined by one or more conditions. A condition includes a field name, an operator, and potentially, a value. The list of available operators is determined by the type of field (string, number, or date).
For example, if the date for a pipe replacement should only be editable if an the pipe_replaced field value is yes, the following condition can be used to build the expression:
Here is what the same expression looks like in Arcade syntax:
($feature, "pipe_replaced") == "yes"
To create more complex expressions, click Launch Arcade editor.
If you use multiple conditions, you can choose whether all conditions must be true or only one condition must be true for the form element to be editable.
ArcGIS Online applies the Arcade Form Constraint profile to evaluate whether a feature meets the criteria defined in the expression.If a value other than
4367is entered in the inspector ID field, the pipe ID field the will not be editable in the form.
An </> Editable chip appears on the form element, indicating that the required expression has been applied.
Now that you created the expression, you can apply it to any form element. You can see which elements are using the expression by clicking the number next to the expression in the Expressions pop-up. See Reuse expressions to learn more.
You can duplicate, edit, or delete the expression at any time using the overflow menu in the Expressions pop-up. To edit the expression using Arcade, click Edit Arcade from this menu.
Add expressions to calculate field valuesYou can add a calculated expression to the form to calculate and populate data automatically. This saves time for editors and enforces data integrity by automating the calculation of the field value.
Use Arcade to build calculated expressions based on feature attributes and geometry. For example, you can add a calculated expression to a field that stores dates for a bridge inspection schedule. When the editor sets the bridge condition field's value to damaged, for example, the expression defined on the inspection date field can automatically schedule the next inspection to take place in a week's time by populating the bridge inspection field with that date.
Calculated expressions are dynamic, meaning they automatically update the form as information changes. As a result, editors can see the updated calculation before submitting the form. Because the value in the calculated expression field is populated by the expression, editors cannot type a value for that field in the form.
To create a calculated expression, complete the following steps:
If editing is enabled for the form element, the expression will not run.
The Arcade editor window appears. The editor allows you to write and test an expression before saving it to the selected form element.
For example, the following expression checks whether polygon feature geometry is null before calculating the area in square meters. Additional examples are provided in the next section.
if (IsEmpty(Geometry($feature))){
return;
}
else{
Area($feature, 'square-meters')
}
To learn more about calculating area with
Arcade, see
Area (Geometry Functions).
For a list of all the functions offered in Arcade, see the Arcade Function Index.
A </> Calculated chip appears on the form element, indicating that the calculated expression has been applied.
Now that you have created the expression, you can apply it to any form element by selecting the form element and clicking the expression you created. You can see which elements are using the Arcade expression by clicking the number next to the expression in the Properties pane under Calculated expressions.
You can duplicate, edit, or delete the expression at any time from the Calculated expressions menu.
Calculated expression examplesThe following are examples of calculated expressions:
if (IsEmpty(Geometry($feature))){
return;
}
else{
var parcels_FS = Intersects($feature, FeatureSetByName($map,"Redlands parcels"));
if (Count(parcels_FS) == 1){
return Text(First(parcels_FS).ZIP_CODE);
}
}
To learn more about extracting information from intersecting layers with Arcade, see Intersects (Geometry Functions).For a list of all the functions offered in Arcade, see the Arcade Function Index.
Reuse expressionsAfter you create an expression, you can reuse it across form elements. For example, you can conditionally display one form element based on the same expression used to require another, and you can use the same calculation to populate multiple fields.
Follow these steps to use existing expressions for form elements:
The Expressions pop-up or Calculate expressions pop-up appears, displaying expressions previously created for the form.
Tip:The number next to the expression indicates the number of form elements the expression is currently applied to. Clicking this number opens another pop-up that displays the form elements and their properties that are currently using the expression.
You can remove the expression from any form element property by clicking the X on the chip displaying the expression type.
A chip appears on the form element, indicating that the expression has been applied.
When you're done editing, save the form. Click OK to close the Configure form window, and save the form to the map or to the layer:
Form changes that are saved to the map override form changes that are saved to the layer.
To save changes to the layer, you must own it, be a default administrator for your organization, or have the following privileges:
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4