Paper Tray Issues on printing RB10.04 D6.2
Hi
We are printing reports out some of which need to be on letterhead which the
client has in Tray 2. Their default on the printer is Tray 1. So they go in
to properties and select tray 2 and print. It still comes out of tray 1
though.
Whatever setting I give it in the report printer setup Tray1, Tray2 etc. and
whatever the user does the report seems to revert to using the default.
Can you shed any light on this? I know printers have drivers and these can
vary in quality etc.
and I am not thinking it is RB doing this as your documentation records
these settings. Have you had any experience with this....
Thanks in advance
We are printing reports out some of which need to be on letterhead which the
client has in Tray 2. Their default on the printer is Tray 1. So they go in
to properties and select tray 2 and print. It still comes out of tray 1
though.
Whatever setting I give it in the report printer setup Tray1, Tray2 etc. and
whatever the user does the report seems to revert to using the default.
Can you shed any light on this? I know printers have drivers and these can
vary in quality etc.
and I am not thinking it is RB doing this as your documentation records
these settings. Have you had any experience with this....
Thanks in advance
This discussion has been closed.
Comments
Are you setting the bin name in code or are your users setting this from the
print dialog?
When setting the bin name, you need to be sure you are using the exact name
the driver uses. The best way to be sure of this is to use the
PrinterSetup.BinNames property.
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
The printer has AQuto Tray Select, Tray 1 and Tray 2 so they are different
spellings to the report.
I just want the one the user selects. Is there anyway to just say 'go with
the user selection'
I'm still unclear about how your users are selecting a bin to use. Are they
using the print dialog in ReportBuilder or selecting this as the default in
their windows printer settings.
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
They are using the print dialog box and clicking properties. They select the
tray and the report goes to the default tray regardless of the selection
they made.
Having looked through other news items I tried the following (from one of
your replies I think) with the aim of capturing what their selections are
and using them
procedure TfrmReportViewer.clrMainPrintDialogCreate(Sender: TObject);
var
lPrinter: TppPrinter;
begin
{intitialize printer DevMode}
if not FEmailed then
begin
lPrinter := TppPrinter(clrMain.PrintDialog.Printer) ;
lPrinter.SetDevMode(FDevMode);
end;
end;
procedure TfrmReportViewer.clrMainPrintDialogClose(Sender: TObject);
var
lPrinter: TppPrinter;
begin
// Only do this for documents
if (clrMain.PrintDialog.ModalResult = mrOK) then
begin
if FDocument then AddArchiveDevice(clrMain,
TppPageRequest(clrMain.PrintDialog.PageRequest));
{save printer DevMode}
if not FEmailed then
begin
lPrinter := TppPrinter(clrMain.PrintDialog.Printer);
lPrinter.GetDevMode(FDevMode);
end;
end;
end;
This does not do the trick either. The important bit is the if not FEmailed
then block in both. the rest is just other stuff we do.
regards
Thanks for the clarification. In my testing with a HP LaserJet 5, I am able
to successfully select and print from a tray from the "properties" dialog.
Are you able to recreate this with any printer? What type of printer are
you (or your client) currently using? Are you certain that no tray
selections properly work?
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
My printer here is a XEROX Phaser 6100DN which has tray names inline with
those of reportbuilder so there is no problem. The client is using a fancy
copier, printer Kyocera which has bin names that are not the same as report
builder. When they select the tray 2 bin in properties and select OK in the
print dialog the report just comes out of Tray 1 which is their default tray
and contains blank paper whereas they want tray 2 that has headed
stationary.
All I want is a way to say 'just use whatever they select in properties' to
the report
regards
ReportBuilder retrieves the names of the available bins (trays) from the
Windows API which in turn retrieves them from the printer driver it is
communicating with. The trays your customer is seeing are not provided by
ReportBuilder, they are provided by the printer driver they are using. If
you take a look at the TppPrinterInfo class in the ppPrintr.pas file, you
can see that ReportBuilder simply asks the Windows API for a list of the
available Bin names in the GetDeviceCapability routine.
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
I know they are provided by the printer driver. But when they select one of
them in the properties the report just comes out from the default tray
unless the trays are those that report builder has i.e. tray1, tray2 the
printer they are using has a tray 2 and this seems to cause it to default.
The printer I have has the same tray names that appear in the report
designer and I am fine here.
regards
ReportBuilder does not define any trays itself. All the trays you see (on
your PC or on your customers') are dynamically retrieved from the printer
driver. The fact that your customer has a bin named "Tray2" and you have
one named "Tray2" is purely coincidential as the authors of each driver
named the bins similarly.
When your customer defines "Tray2" this is setting the DEVMODE structure in
the Windows API which is then supposed to be used by the printer driver to
print from the correct bin. Some advanced printers will ignore this
information and use their own custom techniques to determine certain aspects
of a print job. The fact that selecting a different bin works correctly
with your printer as well as my printer leads me to believe that this is a
printer driver issue.
Are you certain the bin with the header stationary is actually "Tray2"?
Have your customers try some other options to be sure the correct bin is not
labeled something different.
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com