Printing option

humantoolhumantool France
edited 7:13PM in FastReport VCL 5
Hi everyone,

First of all, I have a customer who changed printing options on his printer to print in black and white, my report contains some colors and when he print it, it's in color....why ? Is there a property to activate on FastReport ?

Secondly, I would like to know how I could set Output bin on a printer : For some of my report I need to send it to the "down" bin rather than the "up" one.

Comments

  • humantoolhumantool France
    edited 7:13PM
    Ok, I tried again and printing options are used correctly...??..

    Anyway, there remains my second question: I would like to know how to specify the output tray of my pages, either the front tray or the rear tray. How ?

    Regards,
  • edited March 2018
    Hello,

    You can specify Paper Source from Page Settings from File > Page Settings but i am not sure how you can make this in the code.

    Regards,
    boakoms.
    humantool wrote: »
    Ok, I tried again and printing options are used correctly...??..

    Anyway, there remains my second question: I would like to know how to specify the output tray of my pages, either the front tray or the rear tray. How ?

    Regards,
  • PolomintPolomint Australia
    edited 7:13PM
    boakoms wrote: »
    Hello,

    You can specify Paper Source from Page Settings from File > Page Settings but i am not sure how you can make this in the code.

    Regards,
    boakoms.
    I am not sure you can do this in code. [img]style_emoticons/<#EMO_DIR#>/unsure.gif" style="vertical-align:middle" emoid=":unsure:" border="0" alt="unsure.gif" /> - Printers vary significantly and it would be impossible for a Toolset like FastReport to cover all options. - Doing this in code is different from selecting options in Page Settings, because the user has already nominated the Printer, and clicking on the Properties button invokes a Printer-driver supplied Dialog Box - TfrxReport PrintOptions property (TfrxPrintOptions) contains only generic sub-properties and doesn't give access to "Tray" or similar Screenshot shows which sub-properties are available in Delphi (and FR v6.0). Cheers, Paul[/img]
  • humantoolhumantool France
    edited 7:13PM
    Polomint wrote: »
    Polomint wrote: »
    Hello,

    You can specify Paper Source from Page Settings from File > Page Settings but i am not sure how you can make this in the code.

    Regards,
    boakoms.
    I am not sure you can do this in code. [img]style_emoticons/<#EMO_DIR#>/unsure.gif" style="vertical-align:middle" emoid=":unsure:" border="0" alt="unsure.gif" /> - Printers vary significantly and it would be impossible for a Toolset like FastReport to cover all options. - Doing this in code is different from selecting options in Page Settings, because the user has already nominated the Printer, and clicking on the Properties button invokes a Printer-driver supplied Dialog Box - TfrxReport PrintOptions property (TfrxPrintOptions) contains only generic sub-properties and doesn't give access to "Tray" or similar Screenshot shows which sub-properties are available in Delphi (and FR v6.0). Cheers, Paul[/img]
    Hi Paul,
    I'm back on the forum and I discovered your message...and I never received a mail to alert me.... [img]style_emoticons/<#EMO_DIR#>/mad.gif" style="vertical-align:middle" emoid=":angry:" border="0" alt="mad.gif" /> Thanks for your answer, I hoped it would be possible... Regards, Guillaume[/img]
  • PolomintPolomint Australia
    edited 7:13PM
    Pas de probl??me, Guillaume! >
  • LurkingKiwiLurkingKiwi Wellington, New Zealand
    edited January 2019
    Polomint wrote: »
    Polomint wrote: »
    Hello,

    You can specify Paper Source from Page Settings from File > Page Settings but i am not sure how you can make this in the code.

    Regards,
    boakoms.
    I am not sure you can do this in code. [img]style_emoticons/<#EMO_DIR#>/unsure.gif" style="vertical-align:middle" emoid=":unsure:" border="0" alt="unsure.gif" /> - Printers vary significantly and it would be impossible for a Toolset like FastReport to cover all options. - Doing this in code is different from selecting options in Page Settings, because the user has already nominated the Printer, and clicking on the Properties button invokes a Printer-driver supplied Dialog Box - TfrxReport PrintOptions property (TfrxPrintOptions) contains only generic sub-properties and doesn't give access to "Tray" or similar Screenshot shows which sub-properties are available in Delphi (and FR v6.0). Cheers, Paul[/img]
    In the Windows printer driver architecture, a printer has a configuration record made up of standard parts supplied by Windows and a driver-specific part.
    The Windows API lets you find out how long the private part of the record is, and you can invoke the printer driver's configuration dialogue to set hidden things like colour yes/no, bins, collation etc.
    After that, you can save the record, and restore your pre-set configuration later.
    I've seen a number of questions about it on Stack Overflow, but never managed to get it to work myself (this was before FR).

    This would be ideal for FR to support, as the restoration of the canned config would need to take place inside the FR print process.
  • PolomintPolomint Australia
    edited 7:13PM
    Thanks for the technical detail K1w1. It has been a very long time since I messed around with Drivers! [img]style_emoticons/<#EMO_DIR#>/ph34r.gif" style="vertical-align:middle" emoid=":ph34r:" border="0" alt="ph34r.gif" /> If we do want to promote this as a feature, we should be talking about it on the[/img]Vcl 6 Forum I think, because Vcl 5 is pretty much frozen now.

    Any comment GPI?

    Cheers, Paul
  • gpigpi
    edited 7:13PM
    Printer settings / defaults to handle paper trays? - http://www.fast-report.com/en/forum/?p=/discussion/14025
    wrote:
    First of all, I have a customer who changed printing options on his printer to print in black and white, my report contains some colors and when he print it, it's in color....why ? Is there a property to activate on FastReport ?
    Try something like this:
    procedure frxReport1PrintPage(Page: TfrxReportPage;
      CopyNo: Integer);
    begin
        if frxPrinters.Printer is TfrxPrinter then
        with TfrxPrinter(frxPrinters.Printer) do
        begin
          DeviceMode.dmColor := DMCOLOR_MONOCHROME;
          DeviceMode.dmFields := dmFields or DM_COLOR; 
        end;
    end;
    
    or see here: http://www.fast-report.com/en/forum/?p=/discussion/8809

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.