views:

26

answers:

1

Hi,

I'm working on a project for my companies intranet which requires that multiple attached documents to the main DTO of the project need to be autoprinted in the background. The problem is it's a web project and I want the printing to be done under the surface. Now because it's on an intranet only certain people can use it and I can set a communal printer in the background but I'm wondering hwo to actually print under the surface, the attachments could be anything from photocopy gifs/jpegs to pdf/word docs. Should I use the PrintDocument class? Not really sure how to implement this one. Cheers for any help

A: 

I couldn't find a way to do it under the hood as such so what I did instead was to write a class that merges all the files together into one pdf using OpenOfficePortable and then returned this bulk-print pdf to user via a file stream. For anyone interested here is an article that'll help you get started, it will convert rtf, doc, docx files to pdf. Then use ITextSharp or a similar pdf library to merge the files and return it. Pm me if you're attempting this and having trouble.

Israfel