Hi experts,
Am trying to do print preview using javascript in my asp .net application.
my javascript is like this.
function PrintPanel()
{
var panel = document.getElementById("<%=div_print.ClientID %>");
var printWindow = window.open('', '', 'height=800,width=800');
printWindow.document.write('<html><head><title></title>');
printWindow.document.write('</head><body >');
printWindow.document.write(panel.innerHTML);
printWindow.document.write('</body></html>');
printWindow.document.close();
printWindow.document.close();
setTimeout(function() {
printWindow.focus();
printWindow.print();
}, 500);
return false;
}
--------------------------
but in IE11 am getting a error like
JavaScript runtime error: Unable to get property 'document' of undefined or null reference
in other browsers its working fine.
can any one please help me solve this issue.???
thanks in advance
(Keerthi Kumar)