I am trying to figure out a script that does the following: If you enter text into a text field, a check will appear in a check box. Anyone know how to do this?
Views
Replies
Total Likes
hi Jess2080,
place a textfield and checkbox into the layout from the library,
use the below script for a textfield
Event : exit Language : Javascript
if
(this.rawValue.length >0 )
{
subform1.CheckBox1.rawValue
="1";
}
else
{
subform1.CheckBox1.rawValue
="0";
please find the sample attachment.
Thanks,
Madhu.
Madhu,
I found your answer to be very helpful. After playing around with it, I found this to work:
Event : exit Language : Javascript
if
(this.rawValue.length >0 )
CheckBox1.rawValue
="1";
else
CheckBox1.rawValue
="0";
However, the only problem I am now finding is that I enter text, and the check in the check box appears. Then, if I remove the text, the check box still stays. Any ideas about this?
Thanks,
Jess
Views
Replies
Total Likes
hi Jess2080,
after you remove the text, just come out of that field then you will see the uncheck of checkbox.
this is because we have written the script in Exit event of the Textfield.
Thanks,
Madhu.
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies