I have tried to generate dynamic Control. It is working on FF but IE gives error:
divcntrl[i]is undefined.
Please check the following code:
var mc=document.getElementById("maindiv");
var divcntrl = new Array();
for(var i=0; i<10;i++) {
divcntrl[i]=document.createElement("div");\\error here
divcntrl[i].setAttribute("id","div"+ i);
mc.appendChild(divcntrl[i]);
}
There is no such thing as
<div1>element. Running your code in a fiddle, it runs without errors so the problem is somewhere else. Are you cached with a bad version of the file?I think you would want to code it more like