I have an ASP .NET, VB .NET Web form with 17 yes or no dropdowns.

When no has been selected for the first two dropdowns, I would like to
disable the remaining 15 dropdown boxes.

I attempted:

1.
I first added an autopostback = "True" to ddBox1 and ddBox2

2.
Selected IndexChange ddbox1

If ddbox1.SelectedValue = 'N' And ddbox2.SelectedValue = 'N' Then

ddBox3.Enabled = "False"
ddBox4.Enabled = "False"
ddBox5.Enabled = "False"
ddBox6.Enabled = "False"
ddBox7.Enabled = "False"
ddBox8.Enabled = "False"
ddBox9.Enabled = "False"
'and so on

End If
End Sub

3.
Selected IndexChange ddbox2

If ddbox2.SelectedValue = 'N' And ddbox1.SelectedValue = 'N'

ddBox3.Enabled = "False"
ddBox4.Enabled = "False"
ddBox5.Enabled = "False"
ddBox6.Enabled = "False"
ddBox7.Enabled = "False"
ddBox8.Enabled = "False"
ddBox9.Enabled = "False"
'and so on

End If
End Sub

Item Values for all dropdowns
Selected = "True Value = "" <-Select One->
                         Value = "Y" <Yes>
                         Value - "N" <No>

The error is something like the selected value is not in the item list
-- on page loads.

I hope this is enough information.  Obviously, I am fairly new at the
game.

Does anyone have any ideas???

TW

Reply via email to