Click here to Skip to main content
15,892,674 members
Please Sign up or sign in to vote.
2.00/5 (1 vote)
See more:
I want to print a document from my aspx page.i checked on net.but found all code confusing.please can someone give me a simple code to print a document.Also give me code to export to excel from a grid.

regards
amol
Posted
Updated 19-May-10 1:23am
v2
Comments
DaveAuld 19-May-10 7:22am    
What is simple and what is complex is relative to the users knowledge on the subject. What you going to do if the code you found is as simple as it gets? you would be stuffed then wouldn't you?
Maybe you need to look at the 'complex code' and try and work it out. come up with your own code, and when you get stuck, ask specifics relatin gto where your stuck.
Member 3979606 20-May-10 2:04am    
Reason for my vote of 2
Very Simple.

 
Share this answer
 
Comments
Arun Jacob 20-May-10 4:32am    
I like the 3rd link.
:-)
Ankur\m/ 20-May-10 5:40am    
It suits best to the ICantGoogle people. :P
Use javascript code on trigger event of your control.

window.print();

This will solve your problem.
 
Share this answer
 

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