Copy link to clipboard
Copied
Hello,
I am building a single form that I hope to make multi-purpose using different views.
The first view/function is an internal facing document that a technician will populate much of the information. This will ultimately end up with a sales rep, who can then click a button and create a customer facing document with much of the information retained and a lot of it hidden.
I have almost everything dialed in and I am stuck on maintaining the data initially entered by technician into the 2nd customer view. The fields between the 2 different views are largely the same, but the positioning within the document changes once switched over the to customer view.
What I want to accomplish is having duplicated or linked text fields that once the tech enters it the first time will mirror into the 2nd customer field view (which would be hidden at the time of the tech completing the form).
Best way I can equate it is a cell reference formula in Excel.
Any ideas?
Thanks in adv!
That code is incorrect. It should be:
event.value = this.getField ("name of other field").value;
Copy link to clipboard
Copied
Give the fields the exact same name. That’s all there is to it.
Copy link to clipboard
Copied
I tried that...the problem there is if they have the exact same name, when the sales rep hits the button to switch to the customer view, both fields are hidden.
The issue there is the fields are in different positions w/in the document. Otherwise that would work.
Copy link to clipboard
Copied
Actually, that's not true. You can set the visibility property of each field independently of the others, even if they have the same name.
Copy link to clipboard
Copied
Yes, that sounds right. They are also both hidden or both not. But if you want a field with a DIFFERENT name to hold the same contents as another, you need a script in each field. There are a number of ways to do it. It becomes very complex if you want to allow edits in either mode, easier if one of them can be read only.
Is it practical to put the customer view on the second page?
Copy link to clipboard
Copied
I'd actually prefer the customer view to not be editable.
I already have some scripting built into the form...Im not a wizard but I could try a script solution...just not sure what that is...
Copy link to clipboard
Copied
You can use as calculation:
event.value = this.getField ("name of other field").value;
Copy link to clipboard
Copied
My guy....thank you!
Copy link to clipboard
Copied
That code is incorrect. It should be:
event.value = this.getField ("name of other field").value;
Hi, I am trying to do this at the moment, but the export value shows. How do I get the Item to show instead?
Copy link to clipboard
Copied
The easiest way of doing that is moving the code to the custom Validation script of the drop-down, and change it to:
this.getField("name of other field").value = event.value;
Copy link to clipboard
Copied
Off the top of my head... maybe you could just have a calculation script on each of the customer view fields which sets it value to the corresponding field. Not exactly a calculation, but each calculation script is run every time any field is filled. There may be more efficient ways.