Question

Assyst form visibility expressions

  • 5 December 2022
  • 6 replies
  • 118 views

Can anyone tell me what is causing a visibility expression to be invalid when comparing two different custom fields on an Assyst form?

 

I have a form that has a leaver contact User and I want to compare it’s selected value against the line manager contact user field.  Based on the wiki, I reference fields by prefixing with $W(“<short code>”) and that works fine if I compare one of the fields against a hard coded value but if I try to compare one custom field against another then it complains that the expression is not valid.  

 

Any ideas on what I am doing wrong?

 

   


6 replies

Userlevel 3
Badge +10

If these are lookups to the contact user table you could try:

 

$W("LINE MANAGER").shortCode = $W("LEAVER").shortCode

 

or .name if the name values should match.

Thanks MennovH for your response.  Those options don’t work unfortunately it just complains that the expression is invalid, it seems that while the left side of the expression can be a lookup field, the right hand side can only be a hard coded value.  

Userlevel 3
Badge +10

Are both fields single selects?

 

Are both fields single selects?

 

Yes

Userlevel 3
Badge +10

Okay I just tested on my local system and I get the same error.

It doesn’t like comparing two custom fields with each other.

This seems like a good candidate for a new idea for assyst.

 

Okay I just tested on my local system and I get the same error.

It doesn’t like comparing two custom fields with each other.

This seems like a good candidate for a new idea for assyst.

 

Thanks for looking into it.  Good to know I am not doing something stupid. 

Reply