Hi all,
I know this issue has been addressed (cannot use ‘setAttribute(‘onClick’, ‘somefunc’) in IE). I also have found other forums that talked about just setting the ‘onclick’ function for the element directly (element.onclick = function() {somefunc();};
What I need to do is to set the onclick function dynamically via javascript. Nothing I have done in IE has worked. I.e.
function createCell(record_id)
{
var cell = document.createElement(“td”);
…..
cell.onclick= “function() { somefunc(‘ + record_id + ‘);};”
……
return cell;
}
the way I am trying to set the onclick is causing errors. I tried using ‘eval’ but also received errors.
Any ideas would be greatly appreciated.
thanks,
Bill