laptop and a wrench

Bogue

The Guid() Arcade function does not evaluate in the smart form in ArcGIS Field Maps.

Dernière publication: December 8, 2022 ArcGIS Field Maps
Numéro d’ID de bogue BUG-000151657
EnvoiAugust 18, 2022
Dernière modificationSeptember 26, 2025
S’applique àArcGIS Field Maps
Version trouvée22.2
Système d’exploitationN/A
Version du système d’exploitationN/A
StatutWill Not Be Addressed

Informations supplémentaires

The expression is not correct. Each time the expression evaluates, a new GUID is returned, leading to an infinite loop. Define a GUID initially and check if the field value contains a GUID. If it is empty, create and assign a GUID using the Guid() function. If not empty, return the current GUID field value. For example, to calculate a random GUID in a field, use the following expression and replace FIELDNAME with the name of the field: var id = $feature.FIELDNAME IIf(id==null, guid(), id)

Solution de contournement

Define a GUID initially and check if the field value contains a GUID. If it is empty, create and assign a GUID using the Guid() function. If not empty, return the current GUID field value.

For example, to calculate a random GUID in a field, use the following expression and replace FIELDNAME with the name of the field:

var id = $feature.FIELDNAME

IIf(id==null, guid(), id)

Étapes pour reproduire

ID de bogue: BUG-000151657

Logiciel:

  • ArcGIS Field Maps

Recevoir une notification lorsque le statut d’un bogue change

Télécharger l’application Esri Support

En savoir plus sur ce sujet

Obtenir de l’aide auprès des experts ArcGIS

Contacter le support technique

Télécharger l’application Esri Support

Accéder aux options de téléchargement