Jump to content

Array component data to pop up window without posting form


ssuresh07

Recommended Posts

Hi,

 

I have creating a preview window using pop up, i'm able to get data from textboxes and comboboxes.

 

But i have created dynamic textboxes as array in this form, i'm not able to get those boxes.

 

How to send those data to pop window..?

 

I posted the code below

 

This is the code i used to transfer form data to a pop window

function test()

{

a = window.open("", "", "width=800px, height=600px, resizable");

a.document.write('<html><body><font face="courier new"><table border=1>')

a.document.write('<tr><td colspan=2>Invoice No  : '+ document.add_invoice.txtInvoiceNo.value + '<br>');

a.document.write('Invoice Date : '+ document.add_invoice.txtInvoiceDate.value + '</td></tr>');

a.document.write('<tr><td width=50%>'+ document.add_invoice.txtAddress.value + '</td><td></td></tr>');

a.document.write('<tr><td>'+ document.add_invoice.txtSupplier.value + '</td><td></td></tr>');

a.document.write('</table></font></body></html>')

 

}

 

here is the code i used to create dynamic controls in my form.

 

how to send these textbox value in the above code.

 

var textbox2 = '<input type="text" name= txtDesc[] class="txtbox" style="width:425px" >';

var textbox3 = '<input type="text" name= txtCases[] class="txtbox1" onSubmit="return callMe();" >';

var textbox4 = '<input type="text" name= txtRate[] class="txtbox1" onSubmit="return callMe();" >';

var textbox5 = '<input type="text" name= txtCurrency[] class="txtbox1" >';

var textbox6 = '<input type="text" name= txtAmount[] class="txtbox1" onSubmit="return callMe();" >';

 

var tbl = document.getElementById(tbl);

var rowIndex = document.getElementById(row).value;

var newRow = tbl.insertRow(row_no);

 

var newCell = newRow.insertCell(0);

newCell.innerHTML = textbox;

 

var newCell = newRow.insertCell(1);

newCell.innerHTML = textbox2;

var newCell = newRow.insertCell(2);

newCell.innerHTML = textbox3;

var newCell = newRow.insertCell(3);

newCell.innerHTML = textbox4;

var newCell = newRow.insertCell(4);

newCell.innerHTML = textbox5;

var newCell = newRow.insertCell(5);

newCell.innerHTML = textbox6;

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.