Need advice for dropdownlist control
Hello: I recently made the move from visual studio 2005 to 2012. I have a new assignment at work to create a web app.
I have a form that needs to have a dropdown on it. The user will look to see if there's a value in the dropdown that they want.
this dropdown is bound to values in my sql db.
If they don't see the value they need, they need to add it. I have recently learned that this is not possible to do using the dropdownlist control.
I wanted to come on this forum to get ideas of ways that people incorporate work-arounds for this issue.
It's tough to decide which way to go so hoping to get some ideas and pros and cons of each. e.g.
I've heard of adding a text box control directly under the dropdownlist. Do you think this is the most common approach?
Thanks,
Proctor
Re: Need advice for dropdownlist control
The problem is not the dropdown as such. It's the binding. To add to a list bound to a datatable you need an editing control capable of producing datarows. In this context you'd need a drop down datagridview. Not possible, you say? Well that's what I thought too but .... http://www.codeproject.com/Articles/...-in-a-ComboBox
Re: Need advice for dropdownlist control
Hello dunfiddlin: thanks for your reply. I'm wondering, have you actually tried this before? You know how in a drop down, when you start typing and it pulls up related data, would this one do that?
Sounds like it would allow the user to add new items which is part of what i'm after.
Let me know what you think. thanks, again.
ps...also looking at the Ajax controls but wasn't sure which to use or if any would work for what I want.
Proctor
Re: Need advice for dropdownlist control
It's on my list of things to try but I haven't as yet got a round tuit. Autocomplete, which I guess is what you're asking for, would not be built in at this stage as far as I've read it. It's a bit of a mad idea at the moment with wrinkles yet to be ironed out but I just thought I should show off how I'm keeping abreast of .... er ... make you aware of all the possibilities.
I hadn't really taken on board that this was intended as a 'web app'. You might well be better asking this question in the ASP forum if that means what it appears to mean.
Re: Need advice for dropdownlist control
thanks again for your help and suggestions. At least it gives me another option to try. I think I'll also do as you suggest and go onto the ASP forum.
Proctor