FeatureForm

Defines the user interface (form configuration) to display when editing a feature. A web map may define forms for editing features in a feature layer. A layer's form definition is available from the FeatureLayer.featureFormDefinition and can be used to create a feature form.

Since

200.4.0

Constructors

Link copied to clipboard
constructor(feature: ArcGISFeature, definition: FeatureFormDefinition)

Create a form that contains a user interface for editing the specified feature.

Properties

Link copied to clipboard

The feature form definition used to define the user interface for the form.

Link copied to clipboard

A description of the form.

Link copied to clipboard

An ordered list of the elements contained by the form.

Link copied to clipboard

The feature displayed in the form.

Link copied to clipboard

If true, the value for a previously visible FieldFormElement is retained when it (or its parent) is hidden. The default is false, meaning the value is cleared when an element is hidden.

Link copied to clipboard
val title: StateFlow<String>

The form title.

Link copied to clipboard

A dictionary mapping from FieldFormElement.fieldName to an array of errors. An empty dictionary indicates that all element's values are valid. Constraints are expressed by the FormInput and the value of FieldFormElement.isRequired of the element. The constraints depend on the type of FormInput. The errors returned for each key is an array of any of the following types:

Functions

Link copied to clipboard

Discards edits to FeatureForm.elements and their associated Feature.attributes. Edits are discarded but the Feature is not refreshed. Values will be reset to the values at the time of FeatureForm creation.

Link copied to clipboard

Asynchronously evaluates all form expressions. An expression can include Arcade FeatureSet functions, which need to be evaluated asynchronously. Upon completion the task provides a set of FormExpressionEvaluationError providing diagnostic information about errors encountered during evaluation of expressions. An empty list indicates no errors were encountered.