C
Colin Small
In my client's Access 2003, ADP application, I want to print reports on
different papercolors depending on a couple of criteria, and accordingly we
have set up a laser with 4 paper drawers.
During the Report_ open event, I check the the availables bins using
DeviceCapabilities (essentially KB Q194789) and try to set
me.printer.paperbin to the appropriate value. This works fine as long as
the values is <= 256, but if it is greater, then I get a "runtime error 5,
Invalid procedure or argument". These values are valid and commonly used -
see below.
If I use the menu/page setup to set the report to a specified printer,
select one of the paperbins and paperbin, then paperbin is successfully set
to the higher values, but these still cannot be re-written.
In the immediate window:
?report_rptcustomer.Application.Printer.PaperBin
257
report_rptcustomer.Printer.PaperBin = 1 to 256 succeeds
report_rptcustomer.Printer.PaperBin = 257 fails
As a temporary workaround, I can set up a report for each configuration and
for each color with a selected print setup. However setting .paperbin
should work and when the project expands to multiple printers, it becomes a
nightmare. There is probably some historic limit check, but does anyone
one have a proper workaround.
Colin
-----------------------------------------
From enumerating DeviceCapabilities
\\mc1\Epson Stylus COLOR 1520 ESC/P
15 Automatically Select
7 Auto sheet feeder
4 Manual Feed Slot
513 Manual Feed (Banner)
8 Tractor Feeder
\\mc1\Fax
1 Default
\\mc1\Lexmark Optra E312
1 Tray 1
4 Manual Feed
6 Man. Envelope
7 Auto Select
\\mc1\Lexmark Optra E312 PS2
15 Auto Select
256 Tray 1
257 Manual Paper
\\mc1\Lexmark T630
1 Tray 1
2 Tray 2
3 Tray 3
257 Tray 4
14 MP Feeder
4 Manual Feed
6 Man. Envelope
7 Auto Select
\\mc1\Lexmark T630 PS3
15 Auto Select
256 Tray 1
257 Tray 2
258 Tray 3
259 Tray 4
260 Tray 5
261 MP Feeder
262 Envelope Feeder
263 Manual Paper
264 Manual Envelope
Microsoft Office Document Image Writer
1 Default tray
EPSON Stylus C82 Series
7 Sheet Feeder
Adobe PDF
15 Automatically Select
257 OnlyOne
ActiveTouch Document Loader
15 Automatically Select
8 Tractor Feed
4 Manual Paper Feed
258 Sheet Feeder - Bin 1
257 Sheet Feeder - Bin 2
different papercolors depending on a couple of criteria, and accordingly we
have set up a laser with 4 paper drawers.
During the Report_ open event, I check the the availables bins using
DeviceCapabilities (essentially KB Q194789) and try to set
me.printer.paperbin to the appropriate value. This works fine as long as
the values is <= 256, but if it is greater, then I get a "runtime error 5,
Invalid procedure or argument". These values are valid and commonly used -
see below.
If I use the menu/page setup to set the report to a specified printer,
select one of the paperbins and paperbin, then paperbin is successfully set
to the higher values, but these still cannot be re-written.
In the immediate window:
?report_rptcustomer.Application.Printer.PaperBin
257
report_rptcustomer.Printer.PaperBin = 1 to 256 succeeds
report_rptcustomer.Printer.PaperBin = 257 fails
As a temporary workaround, I can set up a report for each configuration and
for each color with a selected print setup. However setting .paperbin
should work and when the project expands to multiple printers, it becomes a
nightmare. There is probably some historic limit check, but does anyone
one have a proper workaround.
Colin
-----------------------------------------
From enumerating DeviceCapabilities
\\mc1\Epson Stylus COLOR 1520 ESC/P
15 Automatically Select
7 Auto sheet feeder
4 Manual Feed Slot
513 Manual Feed (Banner)
8 Tractor Feeder
\\mc1\Fax
1 Default
\\mc1\Lexmark Optra E312
1 Tray 1
4 Manual Feed
6 Man. Envelope
7 Auto Select
\\mc1\Lexmark Optra E312 PS2
15 Auto Select
256 Tray 1
257 Manual Paper
\\mc1\Lexmark T630
1 Tray 1
2 Tray 2
3 Tray 3
257 Tray 4
14 MP Feeder
4 Manual Feed
6 Man. Envelope
7 Auto Select
\\mc1\Lexmark T630 PS3
15 Auto Select
256 Tray 1
257 Tray 2
258 Tray 3
259 Tray 4
260 Tray 5
261 MP Feeder
262 Envelope Feeder
263 Manual Paper
264 Manual Envelope
Microsoft Office Document Image Writer
1 Default tray
EPSON Stylus C82 Series
7 Sheet Feeder
Adobe PDF
15 Automatically Select
257 OnlyOne
ActiveTouch Document Loader
15 Automatically Select
8 Tractor Feed
4 Manual Paper Feed
258 Sheet Feeder - Bin 1
257 Sheet Feeder - Bin 2