Skip to main content
Inspiring
July 6, 2021
Answered

Radio Button populated Combox-Combox populates TextBox

  • July 6, 2021
  • 2 replies
  • 612 views

Hi Everyone. Thanks for your help in advance....

 

I am working on getting a Combox to change its values. That works. Now I am working on that Combox changing a TextBox based on an ARRAY of choices set when the Combox is set....

I am almost there...but the TextBox does not change until it loses its Focus....got me stumped.

I have attached my test form for convienence.

 

function SetArrayValues(cChoice) { //app.alert(PassToTextBox +" var PassToTextBox passed to SetArrayValues from Radio Button") // Place all prepopulation data into a single data structure //var Choice = PassToTextBox switch (PassToTextBox) { case "Choice1": var ArrayData = { C1Item1:{ statement: "ComboBox Choice1-Item One",}, C1Item2:{ statement: "ComboBox Choice1-Item Two",}, C1Item3 :{ statement: "ComboBox Choice1-Item Three",}, C1Item4:{ statement: "ComboBox Choice1-Item Four",} }; //this.getField("txChoiceMessage").value = ArrayData[cChoice].statement; break; case "Choice2": var ArrayData = { C2Item1:{ statement: "ComboBox Choice2-Item One",}, C2Item2:{ statement: "ComboBox Choice2-Item Two",}, C2Item3 :{ statement: "ComboBox Choice2-Item Three",}, C2Item4:{ statement: "ComboBox Choice2-Item Four",} }; break; //this.getField("txChoiceMessage").value = ArrayData[cChoice].statement; case "": //app.alert("array did not work!"); this.getField("txChoiceMessage").value = "array did not work!"; break; }; this.getField("txChoiceMessage").value = ArrayData[cChoice].statement; }

 

 

This topic has been closed for replies.
Correct answer Robert Ooley

Silly, me....

 

I failed to check the "Commit selected value immediately" on the Combox Options tab...

 

Rookie move.

 

2 replies

try67
Community Expert
Community Expert
July 7, 2021

In the future you should use the Acrobat forum for such questions: https://community.adobe.com/t5/acrobat/bd-p/acrobat

Robert OoleyAuthorCorrect answer
Inspiring
July 6, 2021

Silly, me....

 

I failed to check the "Commit selected value immediately" on the Combox Options tab...

 

Rookie move.