Copy link to clipboard
Copied
For those that do forms all the time, I'm sure this is super simple. I have a small window to create/design 26 fillable pdf spec sheets, and all need to be able to do the following:
Customer enters an option code in Category 1, then Category 2, the Category 3, and the data popluates into a order # in a field below with a "–" seperating each code.
I've done this before but it was 8 or 9 years ago and I've barely slept since then I tried to cobble the Java together but it does nothing. Help is seriously appreciated. Sorry if I have the wording wrong, I only do forms once a decade... (if there was book on pdf form creation I'd buy it).
Copy link to clipboard
Copied
Try this:
var s1 = this.getField("Category1").valueAsString;
var s2 = this.getField("Category2").valueAsString;
var s3 = this.getField("Category3").valueAsString;
if (s1 && s2 && s3)
event.value = s1+"-"+s2+"-"+s3;
else event.value = "";
Copy link to clipboard
Copied
Try this:
var s1 = this.getField("Category1").valueAsString;
var s2 = this.getField("Category2").valueAsString;
var s3 = this.getField("Category3").valueAsString;
if (s1 && s2 && s3)
event.value = s1+"-"+s2+"-"+s3;
else event.value = "";
Copy link to clipboard
Copied
Thanks! Saved my buttocks.

