Hi Can any body help me..
I want to print a page which contains an image /watermark image which should also be printed on the page.. here my page is printed but 1. the watermark image is not Printed 2. the printed page contains the page number i.e. Page 1 of 1 in header and the site url(http://www.dotnetspider.com/forum/PostForum.aspx) in the footer. I want to avoid the header and footer data..
here is my javascript to print the page content:: strid==is the div to be printed i.e content of page... tbPrint==is the table id
function CallPrint(strid) { var prtContent = document.getElementById(strid); var theImage = new Image(100,449); var thetab=document.getElementById('tbPrint'); theImage.src = "../images/certificatebgimage.jpg"; tbPrint.style.backgroundImage = "url(" + theImage.src + ")"; tbPrint.style.backgroundRepeat ="no-repeat"; tbPrint.style.backgroundPosition="center"; tbPrint.style.backgroundAttachment ="fixed"; var WinPrint = window.open('','','letf=0,top=0,width=670,height=600,toolbar=0, scrollbars=1,status=0'); WinPrint.document.write(prtContent.innerHTML); WinPrint.document.close(); WinPrint.focus(); WinPrint.print(); } Help me for this it is bit urgent...
thanks & regards veena
|
| Author: Koteswara Rao 01 Aug 2008 | Member Level: Gold | Rating: Points: 2 |
function CallPrint(strid) { popup = window.open('','popup','toolbar=no,menubar=no,width=200,height=150'); popup.document.open(); popup.document.write("<html><head></head><body onload='print()'>"); popup.document.write(strid); popup.document.write("</body></html>"); popup.document.close(); }
|
| Author: veena patange 01 Aug 2008 | Member Level: Silver | Rating: Points: 5 |
Hi Koteswara Rao , thanks for the reply but the javascript u sent is not actual i want the javascript i gave i perfectlly working.... but the image or u can say backgroung image of the page is not printing... and the page number in header and url in the footer should not display I have gone through some articles but didn't find the solution
Can any body help me for this it is bit urgent
regards veena
|