Click here to Skip to main content
15,037,388 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

how to print a word document using javascript?

Thanks
Posted

<A HREF="javascript:window.print()">Click to Print This Page</A>
   
Comments
hasbina 27-May-13 5:52am
   
first i want to open a word document from client side and it should work in all browsers.
siddharthrainit 27-May-13 5:59am
   
<iframe src="your document path"></iframe>

to open the your document it will work in all browser
siddharthrainit 27-May-13 6:03am
   
<input önclick="window.print()" type="button">click<input>
<iframe src="http://www.w3schools.com" style="width:100%; height:500px;"></iframe>
hasbina 27-May-13 7:42am
   
hai
i want to open a document in button click then get print that doucment only.
Refer - Print word document through Javascript[^]
Quote:
Javascript has no such functionalities to directly print office documentations. However, you can try opening the word document in an iframe. And use window.print to print the whole page.

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




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