How to question: Added new values to dropdown lists & database

Discussion in 'ASP .Net' started by Chris Becker, Jul 2, 2003.

  1. Chris Becker

    Chris Becker Guest

    This is my attempt to rephrase a question I asked earlier that got no
    response. I suspect it was my poor/unplanned wording. Here is another
    attempt:

    I have a form with some drop down lists. I would like the user to be able
    to start filling in the form, then get to one of the dropdown lists (ex:
    Service Type) and realize that the dropdown list does not contain the entry
    that they need. So next to the Service Type drop down list is a
    link/image/button/whatever that they can click to bring up a new window ( or
    ???) to add that new Service Type item. When they save this new Service
    Type item's information, it will be added to the database ServiceTypes table
    in the db, the Add Service Type window will close, and the form that they
    were originally filling out will be preserved, but refreshed to show the new
    service type in the drop down list.

    I'm not asking for exact code necessarily, just some general concepts/links
    on how others have accomplished it. I am looking for a more elegant way
    than saving each field's data into some temp storage and refreshing the
    whole page to add the new service type item, then returning the user back to
    the original form and re-filling all of the fields with the stored values.

    Thanks
    Chris
     
    Chris Becker, Jul 2, 2003
    #1
    1. Advertising

  2. Sounds like you'll be needing to use some client side javascript.
    You can open a new window using javascript such as this:
    a=window.open('http://localhost/TestWebApp/Test.aspx','_new')
    There are all kinds of options for setting window properties such as window
    size and toolbar visibility.
    Here's more info:
    http://msdn.microsoft.com/workshop/author/dhtml/reference/methods/open_0.asp

    From that new window you can reference the original parent window with
    thisjavascript reference:

    window.opener

    Here's more info on that:
    http://www.mozilla.org/docs/dom/domref/dom_window_ref77.html

    --
    I hope this helps,
    Steve C. Orr, MCSD
    http://Steve.Orr.net


    "Chris Becker" <> wrote in message
    news:...
    > This is my attempt to rephrase a question I asked earlier that got no
    > response. I suspect it was my poor/unplanned wording. Here is another
    > attempt:
    >
    > I have a form with some drop down lists. I would like the user to be able
    > to start filling in the form, then get to one of the dropdown lists (ex:
    > Service Type) and realize that the dropdown list does not contain the

    entry
    > that they need. So next to the Service Type drop down list is a
    > link/image/button/whatever that they can click to bring up a new window

    ( or
    > ???) to add that new Service Type item. When they save this new Service
    > Type item's information, it will be added to the database ServiceTypes

    table
    > in the db, the Add Service Type window will close, and the form that they
    > were originally filling out will be preserved, but refreshed to show the

    new
    > service type in the drop down list.
    >
    > I'm not asking for exact code necessarily, just some general

    concepts/links
    > on how others have accomplished it. I am looking for a more elegant way
    > than saving each field's data into some temp storage and refreshing the
    > whole page to add the new service type item, then returning the user back

    to
    > the original form and re-filling all of the fields with the stored values.
    >
    > Thanks
    > Chris
    >
    >
     
    Steve C. Orr, MCSD, Jul 2, 2003
    #2
    1. Advertising

  3. Chris Becker

    David Waz... Guest

    I like to keep that kind of stuff on the same page if I
    can.

    you can put the "add new thing" controls next to the drop
    down, with visible set to false. Clicking the icon makes
    it visible. They add the info, click the Add button in
    that section, and you bind the drop-down to the table, now
    with the new value.

    >-----Original Message-----
    >This is my attempt to rephrase a question I asked earlier

    that got no
    >response. I suspect it was my poor/unplanned wording.

    Here is another
    >attempt:
    >
    >I have a form with some drop down lists. I would like

    the user to be able
    >to start filling in the form, then get to one of the

    dropdown lists (ex:
    >Service Type) and realize that the dropdown list does not

    contain the entry
    >that they need. So next to the Service Type drop down

    list is a
    >link/image/button/whatever that they can click to bring

    up a new window ( or
    >???) to add that new Service Type item. When they save

    this new Service
    >Type item's information, it will be added to the database

    ServiceTypes table
    >in the db, the Add Service Type window will close, and

    the form that they
    >were originally filling out will be preserved, but

    refreshed to show the new
    >service type in the drop down list.
    >
    >I'm not asking for exact code necessarily, just some

    general concepts/links
    >on how others have accomplished it. I am looking for a

    more elegant way
    >than saving each field's data into some temp storage and

    refreshing the
    >whole page to add the new service type item, then

    returning the user back to
    >the original form and re-filling all of the fields with

    the stored values.
    >
    >Thanks
    >Chris
    >
    >
    >.
    >
     
    David Waz..., Jul 3, 2003
    #3
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Bennett Haselton
    Replies:
    1
    Views:
    517
    John M Deal
    Nov 8, 2004
  2. =?UTF-8?B?w4FuZ2VsIEd1dGnDqXJyZXogUm9kcsOtZ3Vleg==

    List of lists of lists of lists...

    =?UTF-8?B?w4FuZ2VsIEd1dGnDqXJyZXogUm9kcsOtZ3Vleg==, May 8, 2006, in forum: Python
    Replies:
    5
    Views:
    410
    =?UTF-8?B?w4FuZ2VsIEd1dGnDqXJyZXogUm9kcsOtZ3Vleg==
    May 15, 2006
  3. Replies:
    2
    Views:
    441
  4. Bon
    Replies:
    0
    Views:
    99
  5. Evan
    Replies:
    3
    Views:
    124
    Bart Van der Donck
    Sep 8, 2004
Loading...

Share This Page