www.webdeveloper.com
Results 1 to 4 of 4

Thread: Combo box with textbox

  1. #1
    Join Date
    May 2006
    Posts
    8

    Combo box with textbox

    hi guyz! its my first time to post here...

    let me explain this briefly so anyone could understand...

    first , here is my table. (though its not like a table). ID, ITEM and POINTS as my Fields.
    ITEM has corresponding POINTS...
    for example, ITEM "notebook" has "10" POINTS.. and so on..

    ID: 1, 2, 3, 4
    ITEM: notebook, ballpen, pencil, book
    POINTS: 10, 5, 5, 50

    now, ITEM is a combobox that contains the records..
    then POINTS are in the textfield format..

    now, in the webpage, i have to choose for example "Ballpen" in the combobox.
    and then the POINTS must appear "5" in the textbox...

    how will i do the ASP coding? i am using dreamweaver..

    thankz for ur replies...

  2. #2
    Join Date
    May 2006
    Posts
    8
    will some one answer my query? or is there some thread similar to this Topic? or if ever that you can't understand what my Q is, then tell me.. plz answer. thankz.. I badly need ur help coz thats my project.. and i need the solution for it badly.. thankz

  3. #3
    Join Date
    Jun 2004
    Location
    Kansas City, MO
    Posts
    1,607
    well you could go about this many of ways.

    1). When the user selects the Item submit the page and get the value of Points and then populate the textbox.

    2). When you are loading the values of Points into the combobox, you could also create an array of points. Then store the array value into a hidden textbox and use javascript to select the correct Point value and populate the textbox.

    3). Load a javascript array and then use javascript to select the correct amout of points when the user selects a value from the combobox. You can use the onChange event of the <select> element.

    There are a couple of other things that you could also do.

  4. #4
    Join Date
    May 2006
    Posts
    8
    ok thanks.. can u pls give me a code for this?

    for number 2 and 3? thankz bro

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles