Attribute Rule Error Message in Portal for ArcGIS

1944
4
Jump to solution
02-13-2021 11:18 AM
CalebMeliesPearce
New Contributor II

Hello,

 

I have an Immediate Calculation Attribute Rule on a Feature Service Layer.  This rule will check the value of an attribute and throw an ErrorMessage object if the requirements are not met.  This rule is working as expected.  In Pro I receive the error message and I also can confirm it is being logged at the Warning level in ESRI Server Manager Logs. When interacting with this rule in online maps via Portal for ArcGIS, I am noticing the behavior where the rule is firing and completing as expected, however the error message is never displayed.  I can see the message in Server Logs and if I use the Batch Attribute Editor Widget, I can see the error message in the Developer Console, but it is never displayed to the user.  While this does still prevent bad data from making it into the DB, the user will never know their edits were abandoned.  Is there a way to display Attribute Rule ErrorMessages in web... besides the console?

1 Solution

Accepted Solutions
CalebMeliesPearce
New Contributor II

Hi @XanderBakker & @HusseinNasser2,

I've answered my own question... The only web map editor tool/widget that is advanced enough to handle the Attribute Rule error message/response is the Smart Editor widget.  This does exactly what I was asking about.  Thank you both for weighing in!

View solution in original post

4 Replies
XanderBakker
Esri Esteemed Contributor

Hi @CalebMeliesPearce ,

I'm just wondering if you should do this with an immediate calculation attribute rule and not a validation attribute rule. But when you use a constraint of validation attribute rule, you probably need to have validation capabilities enabled on the services and meet a couple of other requirements...

https://pro.arcgis.com/en/pro-app/latest/help/data/geodatabases/overview/evaluate-attribute-rules.ht...

https://pro.arcgis.com/en/pro-app/latest/help/data/geodatabases/overview/share-datasets-with-attribu... 

0 Kudos
CalebMeliesPearce
New Contributor II

@XanderBakker unfortunately, validation attribute rules are only available for Deferred evaluation.

https://pro.arcgis.com/en/pro-app/latest/help/data/geodatabases/overview/evaluate-attribute-rules.ht...

 

How are Attribute Rule ErrorMessages displayed in web maps via Portal for ArcGIS?

0 Kudos
XanderBakker
Esri Esteemed Contributor

Hi @CalebMeliesPearce ,

 

I am tagging @HusseinNasser2 to see if he can help you with this question.

0 Kudos
CalebMeliesPearce
New Contributor II

Hi @XanderBakker & @HusseinNasser2,

I've answered my own question... The only web map editor tool/widget that is advanced enough to handle the Attribute Rule error message/response is the Smart Editor widget.  This does exactly what I was asking about.  Thank you both for weighing in!