Click here to Skip to main content
15,891,976 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi.
I want to develop a printing component using asp.net with c#.
This component fetch printers connected in the network and select the printer and send a txt/word/pdf file to print.


pls send a code for how to print print pdf file with out using any acrobat libraries.


pls send the code its urgent.
Posted
Updated 26-Jul-10 8:12am
v2
Comments
E.F. Nijboer 26-Jul-10 12:07pm    
did you try any effort yourself?
Pickettt 17-Mar-17 5:04am    
Very short solution to this:

string filePath = "Sample.docx";
DocumentModel document = DocumentModel.Load(filePath);

string printerName = "Sample";
document.Print(printerName);

The complete sample is shown in this example for printing word, pdf, etc. files in C#. The sample is a WPF application, but you can use the same approach for ASP.NET, also it does not use acrobat library but instead uses this .NET library for Word.

As it's urgent, the code you require is:

CTRL-P

 
Share this answer
 
Comments
Toli Cuturicu 26-Jul-10 16:03pm    
Reason for my vote of 5
Very nice!
Here is what is expected by enquirers:
1. TRY first what you want to do!
2. Formulate what was done by you that looks like an issue/not working.

Try them and tell if you face issues.
Members will be more than happy to help like this.
 
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