Question Load Dropdown when another Dropdown isChanged

Joined
Dec 24, 2019
Messages
10
Location
Florida, USA
Programming Experience
Beginner
Hello!
I have 3 dropdowns to do a search . year , make and model dropdowns. I need to load the model dropdown when the make dropdown isChanged.all data will be pulled from a MSSql database, can anyone point me to a resource that would help me figure out how to accomplish this?

I have the dropdowns getting loaded from the database with all the years , makes and models. would like to have the model dropdown be empty until the end user selects a make. then the model dropdown gets populated with the models that match the make....I hope that makes sence.

thank you for any help.
 
As I recall, the UpdatePanel requires JavaScript to be available on the browser for it to update. So even though you aren't writing the JavaScript, there is still some JavaScript running to do the updates.
 
thank you all for your answers. but I was hoping to get this done without using javascript of ajax(if that is even possible). the one answer I can up with is having a 3 step process..where the end user selects the year and make the clicks submit and is rerouted to a new page where they can select the model, then is rerouted again to the page with the results listed. this isnt the most elegant way to do it but it is all i can think of the get the job done without using javascript or ajax.
 
Why are you trying to avoid ajax and js?

Your suggestion is terrible.

Why would the suggestion I proposed not appeal to you? If you search this forum for update panel and perhaps my name, you will find sample code tested and working where I have provided an example of using the update panel for another user with a similar question.
 
Yes, why avoid JavaScript and AJAX? No modern web browser works without JavaScript. It's not 1990 anymore.
 
I have nothing against javascript or ajax, I was only hoping to get this done without it. I will search the forum for your answer with the updatepanel , Sheepings.
is the update panel available in MVC?
 
It's available in Asp.Net. To use it in MVC would require you to use a partial postback. Try using one of the ajax helpers.
 
Back
Top Bottom