Selecting a paperbin in VBA

a3b
04-28-2008, 01:30 AM
Is there a way to select a paperbin for each page to be printed ?

Timbo
04-28-2008, 03:41 AM
Yep :)

Look up the 'PaperSize Property' topic in your VB help, or...
http://msdn2.microsoft.com/en-us/library/aa173220(office.11).aspx

a3b
04-28-2008, 07:42 AM
Papersize would be nice if I had to print different sizes. I already checked that possibility.
The workbook I need ta have printed, needs a cover with the same papersize as the rest. This cover is in a different paperbin. So actually I need some sort of property in the PageSetup, but there isn't.

As to the PrtDevMode you are referring to in the msdn article, this is intended for Microsoft Access and not for Excel.

I am looking for some sort of API related tool.

Timbo
04-28-2008, 09:48 AM
Well the 'PrtDevMode' is not specific to Access, though the Access Report property of the same name clearly is. I'm afraid I can't locate a "clean" example for you right now, but at least the following shows how to open a printer handle, rather than relying on that Access Report property:

http://www.dbtalk.net/comp-databases-ms-access/why-must-i-use-prtdevmode-13760.html

There's a lot of gumpf in that example, so be prepared for some serious debugging!

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum