This is the repository with screenshots and Arcade code that was used during the tech-session at the European Developer Summit 2024 in Berlin.
Mobile workflows can be streamlined and made smarter by combining ArcGIS Field Maps with Arcade. This session will focus on the how Arcade can be used within the map to provide an intuitive experience when exploring data and how it can be used to configure smart forms for data capture. As well as showing examples the session will also share advanced Arcade patterns and best practices for use in the Field.
The Arcade-code for the in the symbology used expression can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/d1941323f0e89e8bcf3871fd385ac2b9621f2a42/arcade-symbology
The Arcade-code for the in the labels used expression can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/0e595115050ab2b33c81fb16216dacd4eccb7b3e/arcade-labels
The same Arcade expression logic was used for all the attributes that should be used in the bar chart in the popup. So, one has to create several Arcade expressions which point to a different attribute value (in this use case it was the tree health issue type). The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/9023fce1bc87373ed1fdea3ea031683686f7cf78/arcade-popup-boundary-layer-nationalpark
The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/c65ad7f933da07dc26717fece3380ef1ae046a4f/arcade-popup-expression-1-tree-observations-text-block The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/7b92de3ec7cdfc5ffafc9da0bec822f279a54b42/arcade-popup-expression-2-tree-observations-text-block
The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/491da263fc5db62fe36c9b74bfe9d0c767240ada/arcade-popup-tree-observations-arcade-block
In the Field Maps Designer on the form for the Tree Health Observations, the following groups were created and filled with attributes:
Two attributes were set as required and a Info Text Box was included for information.
Nothing special was set in this group. All the 4 attributes contain list values to select.
This group is conditionally visible. It contains two attributes from which one is conditionally required.
The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/d4e377cc6d5e4ce52a6fe5ca46efb703d37c0702/arcade-form-conditional-visibility-group-information-on-pest
The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/af390ec65672310cb3028f72ef4806fe81729e03/arcade-form-conditionally-required-group-information-on-pest
This group is conditionally visible. It contains one attribute, which is conditionally required.
The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/513ff950b8f9edfc7db1598a425926571c9440ce/arcade-form-conditional-visibility-group-information-on-leaning
The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/1c892cada49ce971e2dc1c44bce40d74e1ea8316/arcade-form-conditionally-required-group-information-on-leaning
This group contains a Info Text Box that is conditionally visible and includes attribute values and a arcade expression. Furthermore, it contains a required attribute and an attribute, that is calculated by an arcade expression and thus, read-only.
The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/60d1c25b923d4adc4fab0d0a436bd39477a3dc98/arcade-form-info-text-box-expression
The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/23e44b9240e7840b7a26af91a887c082ed6de799/arcade-form-info-text-box-conditional-visability
The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/d57ada32295fcfdc59cea6c1095ea78c17ab91c5/arcade-form-calculated-value-expression-risk-for-hikers
This group has a switch-button attribute and a date attribute, which is calculated by the arcade expression: "Now()" and is only visible if the switch button is activated.
The Arcade code can be found here: https://github.com/chgresri/arcgis-field-maps-using-arcade-to-build-smarter-maps-and-forms/blob/db35a0b54abe91776e4985d1623a18615ff7b77e/arcade-form-conditional-visibility-treatment-information-group-treatment-date
The only Arcade code part the was added is: " && Hour(Now()) <= 9 && Hour(Now()) > 17".