By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,678 Members | 2,192 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,678 IT Pros & Developers. It's quick & easy.

PLEASE HELP W/ Adding item to a 2 dim array

P: n/a
Hi all,

Please help me with the following..it's realy urgent and i tried
everything i could and i can't get it work properly!! Thanks in
advance.

Here's what i'm trying to accomplish:
in my form i have a table with 3 rows (3 input text), in which user
can enter values and then clik save. When he clicks the Save button,
i'd like to be able to add the created items to the end of my table
(by adding rows dynamically to a table) so that can create his own
table dynamicaly with values he wants.
the first row is my table index. goes from 0 to whatever the user
wants....
i know how to add an item to 1 dim array. i know how to insert row to
a table using insertRow() but what i don't know is to put the whole
thing together....

<TABLE ID = "mytable">
<td><INPUT TYPE="Text"NAME="TxtIndex" value=""></td>
<td ><INPUT TYPE="Text"NAME="TxtName1"></td>
<td ><INPUT TYPE="Text"NAME="TxtName2"></td>
<input type="button" value ="Save" onclick="addItemToArray();">

i want my addItemToArray() method to create new rows (with the right
index and with values given by the user!!) any idea???

please please please please please please

Tx a million!
Jul 20 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Never mind guys! figured out how to do this!
tx!
ho*****@yahoo.com (HolaGoogle) wrote in message news:<cd*************************@posting.google.c om>...
Hi all,

Please help me with the following..it's realy urgent and i tried
everything i could and i can't get it work properly!! Thanks in
advance.

Here's what i'm trying to accomplish:
in my form i have a table with 3 rows (3 input text), in which user
can enter values and then clik save. When he clicks the Save button,
i'd like to be able to add the created items to the end of my table
(by adding rows dynamically to a table) so that can create his own
table dynamicaly with values he wants.
the first row is my table index. goes from 0 to whatever the user
wants....
i know how to add an item to 1 dim array. i know how to insert row to
a table using insertRow() but what i don't know is to put the whole
thing together....

<TABLE ID = "mytable">
<td><INPUT TYPE="Text"NAME="TxtIndex" value=""></td>
<td ><INPUT TYPE="Text"NAME="TxtName1"></td>
<td ><INPUT TYPE="Text"NAME="TxtName2"></td>
<input type="button" value ="Save" onclick="addItemToArray();">

i want my addItemToArray() method to create new rows (with the right
index and with values given by the user!!) any idea???

please please please please please please

Tx a million!

Jul 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.