ASP.net example needed - loading a DropDownList based on value selected on another DDL

K

Keith-Earl

Please direct me to an example of loading a DDL based on user input in a
text box or another DDL.

For example, Florida has 67 counties and six regions. Initially we want all
67 counties to be loaded in the COUNTY DDL. If a user selects NORTHWEST
from the REGION DDL we want to subset the COUNTY DDL to only contain the
counties for that REGION, 12 to be specific.

Can this be done in ASP.NET without many round trips? We currently
implement this feature in Classic ASP using Remote Scripting. While RS is
making a round trip to the database, the user has no idea what is going on.
If we have to make the page blink that will be okay but not preferred.

Thanks,

Keith
 
B

bruce barker

you can do it setting autopostback=true for the ddl. unlike when you do this
with RS, its a standard async post, so the user can change the value in the
drop down before the postback completes (try the down arrow on the ddl), so
client script must be added to prevent this.

I'd use all client code and skip the roundtrip altogether.


-- bruce (sqlwork.com)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top