Copy link to clipboard
Copied
I'm new to forms and scripting. I'm trying to get a value from a single checkbox into a textfield. I have multiple checkboxes so I only want one to be checked at a time. There are 3 boxes that have the same value, but I still need to have just one checked. (there is other info on the form that another department uses, but isn't important for this) I read that the checkboxes can be named the same but have different export values, I have entered the info for each checkbox. my problem is I can't get anything to display in the textbox. I'm sure there is more to the script that I'm using, I just don't know what it is.
this.getField("cutsize").exportValues = [event.value];
Copy link to clipboard
Copied
Just to point out, you used two different field names in your post, "CutSize" and "Cutsize".
Give those 3 checkboxes unique export value like: A, B and C, then use this script:
var check = this.getField("Cutsize").valueAsString;
if(check!="Off"){
if(check=="A"||check=="B"||check=="C")
event.value = '7 9/32"';
else
event.value = check;}
else
event.value ="";
Copy link to clipboard
Copied
So I figured most of this out. I'm just haveing proplems with the 3 boxes with the same vaules in them. I need them to be checked individually so not to confuse a different department. Here is the script I'm using .
event.value = this.getField("CutSize").value;
if (this.getField("Cutsize").value =="Off") event.value ="";
Copy link to clipboard
Copied
Just to point out, you used two different field names in your post, "CutSize" and "Cutsize".
Give those 3 checkboxes unique export value like: A, B and C, then use this script:
var check = this.getField("Cutsize").valueAsString;
if(check!="Off"){
if(check=="A"||check=="B"||check=="C")
event.value = '7 9/32"';
else
event.value = check;}
else
event.value ="";
Get ready! An upgraded Adobe Community experience is coming in January.
Learn more