views:

5767

answers:

5

I have been looking for documentation related to interacting with MSPaint from the command line. I have only found references to /p, /pt and /wia, but no guidance as to how to use them and their limitations.

I am trying to send some graphics files to the printer and when I drop the file on my printer driver I get a different print output than if I call paint from the command line. I am using the UDC print driver to convert graphics, and I am using paint to send my graphics file to the printer driver in order for my file to convert.

Any ideas?

+3  A: 

I actually suggest you look into doing this in Paint.Net instead. You will have much more freedom.

Geoffrey Chetwood
Paint.Net is excellent. Its a .NET app and open source. Also its entirely scriptable, and there are some good tutes online for this.
Anonymous Type
+2  A: 

I suggest ImageMagick hands down... it's like having Photoshop on the command line!

Sklivvz
I am tied to what i can assume will be on the deployed machine, which is why I am looking at using Paint to send my file to the printer.
steve_mtl
Thanks for your feedback. Imagemagick does not require installation, you can just copy the executables.
Sklivvz
what would he syntax be to send a file c:\foo.bmp to the default printer? I am looking at the doc and it is expansive!
steve_mtl
+1  A: 

I know that mspaint /p filename and mspaint /pt filename both print straight to the default printer. Not sure what /wia does, maybe something to do with Windows Image Acquisition?

Also, as others have pointed out, there are many programs a lot more capable for doing what you want than MSPaint.

Vincent McNabb
A: 

If you have MS Office installed, try the Document Imaging thingy under Microsoft Office > Microsoft Office Tools. I've found it to be good in the past at printing large graphics files at full-page size.

Kyralessa
Seems like it only plays nice with TIF files.
steve_mtl
+1  A: 

What OS (specific version) are you using? The newer versions of Windows support printing graphics files without the need for MS Paint or any other graphics program. It's called the "Photo Printing Wizard" in XP, and you can even just right-click on a graphics file and choose "Print" right from Explorer - no other program required (and no command line switches needed either).

If all you are trying to do is send some graphics files to the printer, and you're able to drag & drop them, then this is what I'd recommend using.

Keithius
I am running on windwos 2003.
steve_mtl
Windows 2003 has the "Photo Printing Wizard" as well.
Keithius