0

Hi all!

this is my first post in this site.. the following code works fine with ff but not with ie 8 - i had given [B]'windowname' [/B]in the place of '_blank' for ff, but that did not allow ie to open the window, so replaced it with blank, now the issue is the 'site' opens, but the code that follows to print and close the page does not work. any solution??

function printWindow()
{       
    windowname = window.open("site","_blank");

    windowname.onload = function() { startPrinting();}
    function startPrinting()
    {       
        setTimeout('windowname.close();',2000);         
        windowname .print();                
    }       
}

Edited by Reverend Jim: Fixed formatting

2
Contributors
2
Replies
3
Views
7 Years
Discussion Span
Last Post by Suresh Vanam
0

Hi all!

this is my first post in this site.. the following code works fine with ff but not with ie 8 - i had given 'windowname' in the place of '_blank' for ff, but that did not allow ie to open the window, so replaced it with blank, now the issue is the 'site' opens, but the code that follows to print and close the page does not work. any solution??

function printWindow()
{       
    windowname = window.open("site","_blank");

    windowname.onload = function() { startPrinting();}
    function startPrinting()
    {       
        setTimeout('windowname.close();',2000);         
        windowname .print();                
    }       
} 

Please let me know if any is having solution to this.

Edited by Reverend Jim: Fixed formatting

0

Hi, Please let me know if any one is having solution to this issue. I am also facing same problem in IE8

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.