Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

Need dropdown choice from one table to be added to a new table with a click of a button

islandgirl23
Level 4
Level 4

Good day,  I have a table which have dropdown lists within it. The table also have several buttons.  One of them is a button which adds a new blank table so that the user can choose whatever they like from the dropdown lists.  There are incidents where a choice from one of the drop down lists will be the same for multiple tables.  I do not want the user to have to choose the same choice every time they create a new table.  I would like the user to click another button which would add the additional table, and also keep certain choices selected in the previous table so that they don't have to choose it every time they create a new table.  Is this possible?  Just to elaborate more:  Example:  The table lists automobiles.  Within the table the user will need to enter 30 automobiles made by "Ford" but the automobiles have different models.  When the user chooses "Ford" from the drop down menu of the first table and enter all pertinent information, I want  "Ford" to be automatically entered into the next table when the button to create a similar table is chosen.

1 Accepted Solution
Mayank_Tiwari
Correct answer by
Employee
Employee

Please check this form in which I have copied the value from the dropdown in one table to the other table, on the click of a button - "Copy".

 

Mayank_Tiwari_0-1640784871037.png

 

 

 

View solution in original post

4 Replies
Mayank_Tiwari
Correct answer by
Employee
Employee

Please check this form in which I have copied the value from the dropdown in one table to the other table, on the click of a button - "Copy".

 

Mayank_Tiwari_0-1640784871037.png

 

 

 

islandgirl23
Level 4
Level 4

Good day,

I'm not sure if this will work.  Your reply is listing "Table2".  Will another table "Table 3" appear listing the same value in it when they click the button again? I will need the form to work like this even if they click it 30 times.  Right now, I have another button on the form which adds a whole blank Table.  In the click event of that button, I have

"if (xfa.host.version<8) {

    xfa.form.recalculate(1);

}

I would like the other button to also add a whole new Table but keep whatever was chosen in the previous Table.

MHWinter
Level 3
Level 3

should the new table still have the dropdown list, and assign the value (i.e. "Ford"), or do you only need the value, not the dropdown list?

 

islandgirl23
Level 4
Level 4

Yes, the new table should have the dropdown list, and assign the value.