Seeking opinion of the wise

Results 1 to 2 of 2

Thread: Seeking opinion of the wise

  1. #1
    Join Date
    Dec 1969

    Default Seeking opinion of the wise

    I have a web form that I am building on the fly. Background: Have a dropdownlist....based on your selection from that list will create the rest of the screen. It will create 1 to 20 more dropdown lists (dynamic based on data). Each time you select one of those 20 dropdownlist, it will fill the next list with data.<BR><BR>My first thought was to create a placeholder, fill the placeholder with dropdownlists created in the codebehind...but the autopostback seems to mess up the screen, and it does not remember what dropdownlist you are on. So my second thought was to create a frame for each dropdownlist and then I would only have to post to the next frame after each selection.<BR><BR>What would you do, if you had to do this project?

  2. #2
    Join Date
    Dec 1969

    Default I wouldn't use postback...

    Why go back to the server just to add another control to the form? Puts a *huge* load on the server.<BR><BR>Why not just use client-side JS to add the other controls?<BR><BR>Or, a simpler way, just put all 20 lists in the form to begin with but use CSS to hide all but the first one. Then, again using client-side JS, you un-hide them one by one.<BR><BR>If the content of list 2 depends on what was selected in list 1, then I might rethink this. (But if, for example, there are 20 possible selections in the first drop down and then you want only the unselected 19 in the second, etc., that would be trivial to do with client side JS.)<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts