Duplex printing 3rd page on different paper tray
Hi,
using RB 14.08 I have this question:
I try to print a document of let's say 4 pages with duplex enabled. What
I want is to print the first 2 pages on a printed paper in bin1 and the
rest on a blank paper in bin2.
This is my code:
case RepRechnung.PageNo of
1:
begin
RepRechnung.Engine.Page.printersetup.BinName :=
dm.FormulareQueryBin1.value;
SetMargin(true);
end;
2:
begin
RepRechnung.Engine.Page.printersetup.BinName :=
dm.FormulareQueryBin1.value;
SetMargin(false);
end
else
begin
RepRechnung.Engine.Page.printersetup.BinName :=
dm.FormulareQueryBin2.value;
SetMargin(false);
end;
The setting for page2 may be useless since duplex is enabled, but the
setting for page 3ff. doesn't work. All pages are printed on bin1.
What am I doing wrong?
thanks Uli
using RB 14.08 I have this question:
I try to print a document of let's say 4 pages with duplex enabled. What
I want is to print the first 2 pages on a printed paper in bin1 and the
rest on a blank paper in bin2.
This is my code:
case RepRechnung.PageNo of
1:
begin
RepRechnung.Engine.Page.printersetup.BinName :=
dm.FormulareQueryBin1.value;
SetMargin(true);
end;
2:
begin
RepRechnung.Engine.Page.printersetup.BinName :=
dm.FormulareQueryBin1.value;
SetMargin(false);
end
else
begin
RepRechnung.Engine.Page.printersetup.BinName :=
dm.FormulareQueryBin2.value;
SetMargin(false);
end;
The setting for page2 may be useless since duplex is enabled, but the
setting for page 3ff. doesn't work. All pages are printed on bin1.
What am I doing wrong?
thanks Uli
This discussion has been closed.
Comments
Where are you calling this code? As a test, try creating a simple 2
page report and try to change the bin for each page using code similar
to yours.
Instead of manually assigning the bin name, try using the
PrinterSetup.BinNames property so you can be sure you are using the
correct value.
Report.PrinterSetup.BinName := Report.PrinterSetup.BinNames[1];
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Sorry not to have mentioned that. I call the code in the OnStartPage event.
I did that, but no change:
procedure TForm1.MyReportStartPage(Sender: TObject);
begin
if MyReport.AbsolutePage = 1 then
MyReport.PrinterSetup.BinName := MyReport.PrinterSetup.BinNames[4]
else
MyReport.PrinterSetup.BinName :=
MyReport.PrinterSetup.BinNames[4];
end;
or (with the same result):
procedure TForm1.MyReportStartPage(Sender: TObject);
begin
case MyReport.PageNo of
1:
begin
MyReport.PrinterSetup.BinName := MyReport.PrinterSetup.BinNames[3];
end;
2:
begin
MyReport.PrinterSetup.BinName := MyReport.PrinterSetup.BinNames[3];
end;
3:
begin
MyReport.PrinterSetup.BinName := MyReport.PrinterSetup.BinNames[4];
end;
end;
end;
In both cases the printer prints to MyReport.PrinterSetup.BinNames[3]
(the 1st paper bin)
With Simplex that works fine, but not with Duplex. Any idea?
Thanks.
Uli
if MyReport.AbsolutePage = 1 then
MyReport.PrinterSetup.BinName := MyReport.PrinterSetup.BinNames[3]
else
MyReport.PrinterSetup.BinName :=
MyReport.PrinterSetup.BinNames[4];
We have not seen this behavior before.
My best guess is that your printer does not support duplex from both
bins. Try disabling duplex before switching bins and see if that solves
the problem.
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
It doesn't seem to be possible to disable Duplex within a print job. But
anyway it doesn't make sense for me to disable Duplex, because I don't
know how pages remain to print.
It's a common scenario (print Duplex on printed paper for the 1st page
and blank paper for the next pages) and quite a common printer (Brother
5370DW) - just ridiculous that the printer driver doesn't allow that.
There is another issue (which I found in this forum as well): when
Duplex is enbabled, the printer starts to print on the back of the page
and turns the content by 180 degrees. So you can't print simplex and
duplex from the same bin. Several printers "work" like this, but some
offer a software solution at least (of course Brother doesn't).
If someone reads this posting and knows a duplex printer which works
like described - please tell me. Much appreciated.
Thanks.
Uli