I've got a program I'm writing that
A. runs as a service
B. grabs a screenshot of a specific window every X number of seconds
C. prints it to the default printer.

A and B are more or less done.
C is confusing me.

I'm looking for a way to print without the PrintDialog coming up. If you can help, that'd be swell.

As best I can tell, my options are:
1. P/Invoke it with Win32 calls. Eh, sure, I guess.
2. Intercept the PrintDialog Eh, no.
3. Printing in an embeddable browser. Not the minimal overhead I was looking for.
4. doc.PrintController = new StandardPrintController(); //I have no idea if that actually works. I'm about to test it.

Yes, apparently number 4 works. That only took my entire day to find.

Facepalm.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.