364,032 Members | 4592 Browsing Online
Community for Developers & IT Professionals
Bytes IT Community

How to cascade dropdown list boxes in ASP.NET

easterbell
P: 4
I am working on a web application in ASP.NET(uses C# language) that consist of using cascading dropdown listboxes. Bascially, after the one item is selected out of the listbox, the next one should automatically display its drop down list. Could someone please help.
Aug 4 '06 #1
Share this Question
Share on Google+
3 Replies


axas
P: 32
(C#)
Expand|Select|Wrap|Line Numbers
  1. DropDownList1_SelectedIndexChanged(object sender, DropDownListCommandEventArgs e)
  2. {
  3.     // here load the other dropdownlist items
  4. }
(VB.NET)
Expand|Select|Wrap|Line Numbers
  1. Protected Sub DropDownList1_SelectedIndexChanged(ByVal sender As Object, ByVal e As DropDownListCommandEventArgs) Handles DropDownList1.SelectedIndexChanged 
  2.  
  3.    'here load the other dropdownlist items
  4. End Sub
Aug 4 '06 #2

nmsreddi
100+
P: 366
hi

for cascading the combo boxes first set the combo box property autopost back=true and then what ever the combos u want to cascade, write the second combo databind code in combo selected indexchange() ,i.e u can write code in what u get by doubleclicking the particular combobox.


hope u got it and may useful



nmsreddi
Aug 9 '06 #3

bindu priya
P: 1
I am working on a web application in ASP.NET(uses C# language) that consist of using cascading dropdown listboxes. Bascially, after the one item is selected out of the listbox, the next one should automatically display its drop down list. Could someone please help.
Hi..
I'm working on a web application in ASP.Net(delphi language) that consists of loading the items to the dropdown list box in the form load event... then if any other event(say button click) is triggered the form load event is automatically called and so the item that i have selected before my event(button click) is changed because the form load event is agained called and so the item in the dropdown list is the first item (itam at form load). So i can't get the query to my selected item instead i'm always getting the query for the first item of the drop downlist box.Hope u people understood my problem.. and do help me i fu know the answer..
Nov 3 '06 #4

Post your reply

Help answer this question



Didn't find the answer to your ASP.NET question?

You can also browse similar questions: ASP.NET