![]() |
|
|
|
| ||||||
|
Welcome to the The ProgrammersTalk Community forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact contact us. |
| Tags: |
![]() |
![]() | | LinkBack | Thread Tools | Display Modes | ![]() |
| |||
| [SOLVED] How to bind a list of items in a dropdownlist based on the selection from another dropdownlist in asp.net? I have Dropdownlist1 which is bound to a database. Now based on the selected item in this dropdownlist, a list of items from the database should be displayed in Dropdownlist2. |
| |
| |||
| So, you have Dropdownlist bound to a datasource Then hook into the DropDownList1's SelectedIndexChanged and in that event say Dropdownlist2.datasource = YourCurrentSource(Filtered by Dropdownlist1.selectedValue) This is not valid code, but I hope you see what I mean... Just have dropdownlist's selectedvalue drive the datasource for dropdownlist2 ![]() __________________ Day Cares | Golf Courses | Disc Golf Courses | Campgrounds | Ice Rinks | Paintball Fields | Dentists | Plastic Surgeons | Aging Jokes Catholic Churches | Lutheran Churches | Methodist Churches | Episcopal Churches | Clean Jokes |
![]() |
| Thread Tools | |
| Display Modes | |
| |