i am using this function to add rows dynamically
function addRow()
{
var tbl = document.getElementById('applications');
var lastRow = tbl.rows.length;
// if there's no header row in the table, then iteration = lastRow + 1
var iteration = lastRow;
var row = tbl.insertRow(lastRow);
// left cell
var cellLeft = row.insertCell(0);
var el = document.createElement('input');
el.type = 'text';
el.name = 'txtRow' + iteration;
el.id = 'txtRow' + iteration;
el.size = 45;
//e1.style.color='blue'
// e1.className="cellData";
//e1.style.width="220px";
//e1.maxlength=20;
//alert("hi")
//e1.style.height=17px;
cellLeft.appendChild(el);
}
when i try to use these :
//e1.style.color='blue'
// e1.className="cellData";
//e1.style.width="220px";
//e1.maxlength=20;
//e1.style.height=17px;
it stops working...
can some one guide me..
i really need to add styles etc to the rows added