ASP.NET does that natively for you:http://www.google.co.uk/search?sourc...hl=en-GB&ie=UT...
Right, but here's what this common method is doing...you pass in the
connection string, and your stored proc name (and parameters, etc) and
it returns a string that would look something like this:
"<select id="cbCarriers" onchange="javascript
: test();"><option
value='241'>3GP</option><option value='441'>AAC</option><option
value='1115'>AB1</option></select>"
I then assigned this string to a protected variable (named
_carrierDropDown) inside .NET and can reference it in my HTML like so:
<%=_carrierDropDown%>
and when I run my app, my control is built with not a lot of code on
my part. The problem is that I now need the selected value from this
control inside .NET when I go to do another DB call (That's why I was
placing that onchange method in the tag). Since this control is A)
built dynamically and B) is a client side control, I'm thinking it
will be very difficult to get the value in the way I need to.
FYI...a lot of what is done here is with javascript/client side
controls vs. server side as the belief is that it performs better for
the user who uses the app outside of our network. Thus why the
control they built with this method is a client one and not a server
one (like the dropdown list you mentioned). Not sure if that is an
accurate belief, but I'm fairly new to web development so don't have
much to go on.