You are viewing limited content. For full access, please sign in.

Question

Question

Using "Add Other Choice" value from a checkbox in a concatenated string field

asked on March 8, 2022

Hi

I am using code provided in this forum to remove underscores from checkbox values and create a concatenated string (without underscores) in a single line text field.  the code provded works perfectly unless I allow an 'Other' selection in the checkbox source field.  I can't get a concatenated string that includes the Other value, I keep getting he error that I have an Invalid Variable.  I don't how to reference the 'Other' checkbox selection and it's inputted value.

This is my source checkbox field

This is the Calculation I put in the advanced tab of a second signle line field in the same form.  It works if I remove the last line about the 'Other' value.

Any help would be appreciated.

=CONCATENATE(IF(MistreatmentType.Unprofessional_behaviour,"Unprofessional behaviour, 
",""),IF(MistreatmentType.Discrimination_discriminatory_harassment, "Discrimination/discriminatory harassment, 
",""),IF(MistreatmentType.Sexual_violence_sexual_harassment,"Sexual violence/sexual harassment, 
",""),IF(MistreatmentType.Unsure,"Unsure, 
",""),IF(MistreatmentType.OtherChoice,MistreatmentType.value,""))

 

0 0

Answer

SELECTED ANSWER
replied on March 8, 2022

Hi Katherine

In place of your last IF for the Other data, you could replace the IF with just 

MistreatmentType._other_data)

This would provide the data from the other field when Other is selected but would provide no data otherwise so no IF would be required

1 0

Replies

replied on March 8, 2022

Thank you!!!  That works.  Very much appreciated.

Katherine

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.