I have a series of calculated "test" fields (stored as either 0 or 1) that I am using in a nested if( ) statement to drive the formatting of a final 'text' field (Artifact Recovery Summary). The if ( ) statement logic and syntax works perfectly fine while the test fields are displayed in the form as 'integer' field types. This is shown in the first screenshot, as the formatting for when both values = 0, the calculation should return the text 'NCM'.
I want the test fields to be hidden in the form, and so I changed the field type from 'integer' to 'calculate'. When I make that one change and refresh the form, it appears to break the if( ) statement logic in the calculated Artifact Recovery Summary field. The result changes from 'NCM' to '0H -- 0P' which is not the correct formatting for that scenario (see second screenshot).
I don't understand why changing the field type from 'integer' to 'calculate' would do this. I am only trying to hide those fields from the survey form, as they only serve to drive logical statements in other fields. I also tried setting the field type to 'hidden' (which I technically don't want, because I don't want these data stored in the feature layer), and I also tried setting the bind::esri:fieldType to 'esriFieldTypeInteger' as well as 'null' and none of those changes made a difference either. I can only get this to work if I leave the test fields displayed as 'integer' fields in the form.
Any thoughts on why this is happening and how to fix it? Again, the if( ) statement logic and syntax is correct. There are no error messages being reported by the software for bad syntax. It just seems like a bug due to an incompatibility between calculate fields and using them in future if( ) statements.
I am using Survey123 Connect on Windows Desktop (Version 3.18.123)
Thanks in advance!
@JamesTedrick, @IsmaelChivite