select box, selectedIndex problems

A

Adam

OK. Here goes...

I have a page in IE 6 that has a row with some input boxes and one
SELECT box. Below this row there is a button that onClick, it adds a
new row to the page dynamically. What it does actually is rewrites
those inputs and SELECTS on the page by first putting them in arrays
and then after writing the boxes, it puts them back where they go.
OK? OK.

So this SELECT box is my problem. The string that defines it, is
written from ASP on page load. It works no problem. Until you add a
row to the page. When a user has already chose a option there, and
then clicks ADD, it resets thier SELECT box to the first option, not
what they chose. I cannot figure out how to find thier choice and
keep it selected. The value of the option corresponds to the number
in the DB... but I can't very well look that up from the DB while the
page is running...

<option Value="231">0001</option> <option
Value="605">0002</option>...etc.

I need to somehow, I guess to retrive the selectedIndex from the
SELECT box, but I have been unsuccessful. I have also tried to put
the index value in a hidden box but also unsuccessfully. That is the
only ideas I have had, and they have not worked for me. Can anyone at
least point me in the right direction?

Thanks in advance!
 
A

Adam

WOW. Thats all I can say. Thats a really cool example. I think that
will help a lot.
Thanks much!
Adam
 

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

Members online

Forum statistics

Threads
473,780
Messages
2,569,608
Members
45,252
Latest member
MeredithPl

Latest Threads

Top