Sure you can, but you might want to do it differently. If you give them all the same field name, the value will automatically get copied to all of the like-named fields. Would that be OK?
I was thinking about doing this, since the fields are set to be hidden until the checkbox unhides the field, but we'd run into issues where multiple people may be filling out the form and need to enter a different set of initials.
You can use a code like this in your check-box's MouseUp event:
if (getField("Check Box1").value!="Off")
getField("Text2").value = getField("Text1").value;
else getField("Text2").value = "";
Of course, you'll need to adjust the names of the fields.
1 person found this helpful
Just as an different but similar approach to above, you could create a document level function something like this
function updateInitials ( location)
this.getField ("init_entry" + location).value = this.getField ("initials").value
then on each checkbox you could have the code something like this
for check_entry1 it would be
for check_entry2 it would be
and so on
Hope this helps
Thanks! That was exactly what I was looking for. I much appreciate it.