F
Flyzone
Hi, i have a little trouble with javascript putting data in a form
html.
I'm parsing an xml file with DomXML (into an hta file), in a loop:
if (i==0) {
document.form.moduleA_0.value = varnameA;
document.form.moduleB_0.value = varnameB;
...
else if (i==1) {
document.form.moduleA_1.value = varnameA;
document.form.moduleB_1.value = varnameB;
...
else if (i==2) {
document.form.moduleA_2.value = varnameA;
document.form.moduleB_2.value = varnameB;
...
And in the html form, many input field idetify by the name moduleA,
moduleB.....
That is very boring.
There is a way to identify them in javascript as 'moduleA_'+i like an
array,
or to write as array? I tried to make a moduleA = new array(10), but i
get many
errors in thml.
Could someone give me some tips? Reading in the old posts didn't help
me (wrong key search?).
Thanks in advance
html.
I'm parsing an xml file with DomXML (into an hta file), in a loop:
if (i==0) {
document.form.moduleA_0.value = varnameA;
document.form.moduleB_0.value = varnameB;
...
else if (i==1) {
document.form.moduleA_1.value = varnameA;
document.form.moduleB_1.value = varnameB;
...
else if (i==2) {
document.form.moduleA_2.value = varnameA;
document.form.moduleB_2.value = varnameB;
...
And in the html form, many input field idetify by the name moduleA,
moduleB.....
That is very boring.
There is a way to identify them in javascript as 'moduleA_'+i like an
array,
or to write as array? I tried to make a moduleA = new array(10), but i
get many
errors in thml.
Could someone give me some tips? Reading in the old posts didn't help
me (wrong key search?).
Thanks in advance