Adding value to a field based on the response in anoter field
Original Post by Sean Docherty (Imported from Ardevia Forum)
Hello,
I have a field called Token Type, that is a choice column with the values of Hard Token and Soft Token.
I have one other field that is a Yes/No column called Cell Phone Required.
I want assistance with how to show a value in a field when another field has a certain value.
As an example:
if Cell Phone Required is Yes then the value in the field Token Type should become Soft Token.
I have tried using the following code in the calculated field
[[Cell_x0020_Phone_x0020_Required]]===true==
[[RSA_x0020_Token_x0020_Type]]=="Soft Token"
Please advise on the best way to do this.
-
Original Post by Andrii Katsiubka (Imported from Ardevia Forum)
Try this solution:
Set calculated expression for Token types field:Code:
=[[<span data-scayt_word="Cell_x0020_Phone_x0020_Required" data- scaytid="1">Cell_x0020_Phone_x0020_Required</span>]] ? "Soft Token" : [[<span data- scayt_word="RSA_x0020_Token_x0020_Type" data-scaytid="2">RSA_x0020_Token_x0020_Type</span>]]
Now Token type will be set to "Soft Token" when check "Cell phone required". But user still able to change this value. So you need to disable token selection field:
Set enabled expression for token types field:
Code:=![[<span data-scayt_word="Cell_x0020_Phone_x0020_Required" data- scaytid="3">Cell_x0020_Phone_x0020_Required</span>]]
0 -
Original Post by Sean Docherty (Imported from Ardevia Forum)
Hello,
Thank you for your response.
I have tried the solution that you proposed and I am running into a couple of issues.1. The script generates an error after I save the form and access the form. Below is the error I get;
Failed value expression Error occurred on evaluating expression "=[[Cell_x0020_Phone_x0020_Required]] ? "Soft Token" : [[RSA_x0020_Token_x0020_Type]]"
Error: Out of stack spaceLink to screen capture - Link to screen Capture
2. The script causes other check boxes to be greyed out and makes the Token Type field disappear all together.
Link to screen capture - Link to screen capture
Please advise
0 -
Original Post by Sean Docherty (Imported from Ardevia Forum)
Hello,
What is the best way to disable the token selection field?
0 -
Original Post by Taras Lozynskyy (Imported from Ardevia Forum)
Hi Sean
Please install the latest version of application from the store. This functionality will be included in it.0 -
Original Post by Sean Docherty (Imported from Ardevia Forum)
Okay I have installed the latest version of the product and it is working fine.
I am happy to see the new features like the Export and Import buttons.Having an issue trying to find out how to disable the field in the new version. Can you please provide instructions on how to do this.
Thank you
0
Please sign in to leave a comment.
Comments
6 comments