Search code examples
c#winformsprintingconsole-applicationsystem.printing

Batch Printing Using Windows Forms in C#


I want to create a windows form application that will sit on our local server and print invoices to a network printer say every 30 minutes.

Can someone confirm that you definitely can't use a console application to print (invoices will include images for logos etc). The reason I ask is that it seems pointless to have a GUI when there's no need for one. If it can, a simple resource to get me going would be great.

Also I can't seem to find an easy to follow tutorial on .net printing basics (positioning data etc). A the moment the whole concept isn't sinking in at all!


Solution

  • If you don't need a UI, perhaps a .Net Windows service will do the job. I have used this method before for exactly this purpose -- every n minutes, it looks for something to print, either in a folder or a database table.

    If you choose this route, here is one of many helpful online tutorials you could use.