Avatar

Level 9

Hello Samuel ,

As far as I understand your question , you want to display the same value as the user selects from the dropdown lists in the textfield.If this is the case then the following script might help you . What you need to do is to capture the value which the user selects from the dropdown list .Then you have to assign the value to that particular textfield.Here you have to use change event as it helps when some changes has been made to the dropdownlist i.e. when the user selects some value from the dropdown list.

form1.page1.pageSelection::change - (JavaScript, client)

    var newVal = this.boundItem(xfa.event.newText);
    form1.page1.TextField1.rawValue = newVal;
    xfa.form.recalculate(true);

Here recalculate is used because  it Forces a specific set of scripts located on calculate events to execute. The specific events can ...pending  calculate events or all calculate events. But I tested it without using recalculate , it works fine . However you should use recalculate.

Hope it helps.

Thanks.

Bibhu.