Print pdf file displayed inside iframe to printer


How can I print a pdf file displayed inside iframe directly to
printer from Firefox/IE?



The following code works in chrome/opera well,but not in IE and
Firefox.





function printIframe(objFrame) {
objFrame.focus();
objFrame.print();
}

<iframe  id="pdfreport"
name="pdfreport" src="1.pdf" width="100%;" height="80%">
</iframe>
<button type="button" style="float: right" name="btnprint"
onclick='printIframe(pdfreport);'>Print</button>




- Technology - Languages
+ Webmasters
+ Development
+ Development Tools
+ Internet
+ Mobile Programming
+ Linux
+ Unix
+ Apple
+ Ubuntu
+ Mobile & Tablets
+ Databases
+ Android
+ Network & Servers
+ Operating Systems
+ Coding
+ Design Software
+ Web Development
+ Game Development
+ Access
+ Excel
+ Web Design
+ Web Hosting
+ Web Site Reviews
+ Domain Name
+ Information Security
+ Software
+ Computers
+ Electronics
+ Hardware
+ Windows
+ PHP
+ ASP/ASP.Net
+ C/C++/C#
+ VB/VB.Net
+ JAVA
+ Javascript
+ Programming
Privacy Policy - Copyrights Notice - Feedback - Report Violation 2018 © BigHow