textbox array index

G

G

Hello friend,

I am using a textbox with in a forloop, for each time when i click a button
it genarates a new textbox, so for example for first time there will be 1
textbox, i will enter some value into that textbox and i click the button
which adds another textbox and i enter someother value and i go on clicking
for to add a new textbox and enters some value. after creating 5 textboxes i
want to know the index of the textbox, basing on thet index i will find the
value and do some calculations and some more. so i must compulsorily need
index of the textbox.

SO can any one help me.
when i see in the view source i am seeing that 5 textboxes names are same.

<input type="text" name="txtStores" id="txtStores" value="0" size="4"/>
<input type="text" name="txtStores" id="txtStores" value="0" size="4"/>
.....
....
....


Thanks
G
 

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

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top