Adding instance with dropdown values of previous instance

Avatar

Avatar
Validate 10
Level 2
Jodi1725
Level 2

Likes

6 likes

Total Posts

113 posts

Correct reply

2 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 1
View profile

Avatar
Validate 10
Level 2
Jodi1725
Level 2

Likes

6 likes

Total Posts

113 posts

Correct reply

2 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 1
View profile
Jodi1725
Level 2

17-03-2016

HI All!

Need some help with some javascript.   I have a form that has a radio button B that when you select it, shows a subform.  Inside the subform is a table that has a dropdown list.  The drop down list is populated based on a previous radio button A that was selected, and is a subset of possible values.

The user is able to click a button to create an additional instance of the subform.  Problem is the new instance is in the original version of the subform, and the drop down list does not have the selected subset of values.

How can I have the dropdown in the added instance only show the subset drop down values?

Let me know if you need more info.

Thank you!

Jodi

View Entire Topic

Avatar

Avatar
Validate 10
Level 2
Jodi1725
Level 2

Likes

6 likes

Total Posts

113 posts

Correct reply

2 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 1
View profile

Avatar
Validate 10
Level 2
Jodi1725
Level 2

Likes

6 likes

Total Posts

113 posts

Correct reply

2 solutions
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 1
View profile
Jodi1725
Level 2

18-03-2016

Hi Magus!

The code that I entered above wasn't working on the click event of the button that adds the additional instance.

So what I did was on the drop down list I tried the following on both the initialize and the enter event, and it still doesn't work.

if (Main.Campus.Urbana.rawValue == "1")

Main.PreApproved.Awardees.Table1.Row1.AwardType.rawValue = "";

Main.PreApproved.Awardees.Table1.Row1.AwardType.clearItems();

Main.PreApproved.Awardees.Table1.Row1.AwardType.addItem("Excellence in Faculty Mentoring Award");

Main.PreApproved.Awardees.Table1.Row1.AwardType.addItem("Excecutive Officer Distinguished Leadership Award");

Main.PreApproved.Awardees.Table1.Row1.AwardType.addItem("Outstanding Faculty Leadership Award");

Main.PreApproved.Awardees.Table1.Row1.AwardType.addItem("Campus Award for Excellence in Instruction");

Main.PreApproved.Awardees.Table1.Row1.AwardType.addItem("Chancellor's Academic Professional Excellence Award (CAPE)");

Main.PreApproved.Awardees.Table1.Row1.AwardType.addItem("Chancellor's Distinguished Staff Award");

Main.PreApproved.Awardees.Table1.Row1.AwardType.addItem("Service Recognition Award")}