I have 3 drop down boxes, created using the HTML select tag. On page load, the first box has a few names. Now, when I click on one of the names in the first box, some more names should appear in the second and when I click on a name in the second box, some more names should appear in the third box. How can I achieve this using AJAX? I have to use ASP.Net and MS SQL Server only. I'm a complete noob to AJAX and I've been educating myself about it, but nothing's working out. I've been looking for the code for close to a week. I looked up w3schools.com, but when I tried that code, it didn't work. Please help me out and please tell me step by step, the things required in order to make it work, and what goes where. I have a deadline that is fast approaching and am at my wit's end trying to make it work. HELP ME!!
相关问题
- Carriage Return (ASCII chr 13) is missing from tex
- Using :remote => true with hover event
- How to store image outside of the website's ro
- Is there a way to play audio on a mobile browser w
- 'System.Threading.ThreadAbortException' in
I would recommend placing the three dropdownlists in an UpdatePanel and adding a trigger to each for the updatepanel. Then, when the value changes, re-populate the dropdown and let the updatepanel push the update. Also keeps session-state in case you want to submit the values.
I don't have a compiler in front of me, but if need be just post a comment and I'll post the code tomorrow.
Working Example
I'm using the "Traditional template" that comes with visual studio and the master page, so excuse the content place holders. But this should demonstrate what I mean: