Click here to Skip to main content
15,910,224 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi
I have a problem in Printing.In my Print i have an image that image is not loaded in Google Chrome.In IE and Firefox the image is showing good but in Chrome it gives empty.

Here is my print code

C#
function CallPrint(strid) {

           
           var strPrint = "<table width=100% border='0'><tr align='center'><td><img src='Images/Image1.jpg' /></td></tr><tr align='center'><td><font face='verdana' size=3><b><u>Hi</u></b></font></td></tr></table>"          
           var WinPrint = window.open('', '', 'left=20,top=20,width=750,height=600,toolbar=0,scrollbars=0,status=0');

           WinPrint.document.write(strPrint);
           WinPrint.document.close();
           WinPrint.focus();
           WinPrint.print();
           WinPrint.close();
       }
Posted
Comments
Tharaka MTR 7-Jan-13 5:47am    
I have checked your code, it is working fine in chrome also. Could you please tell us what is your chrome version?

May be there is possibilites with image path.
 
Share this answer
 
Hi,

Here is a problem, you can view the link for understanding.

Issue while printing an image using javascript

Thanks
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900