How can i use my own printer dialog ?

edited 1:55AM in FastReport 4.0
hello,
how can i use my own printer dialog
i have same skins and there can not design the fastreport printerdialog
many thx for any tip

my poor code for FR-Printdialog is ...
//the report is ok
frxReport1.Print ;


//now my windows-printdialog
//how can i the printdialog tranfer the report??
printdialog1.execute;

ciao
info339

Comments

  • dschuchdschuch Dresden,Germany
    edited 1:55AM
    thats a bit tricky. 1) Search for Printer Bin here in Forum. Exspecially for >TfrxHackedPrinter<

    best is to read the FR-Sourcecode.

    the code should look like this:
    frxReport1.PrepareReport;
    InternalPrint;
    
    procedure Internalprint;
    var
     PrtDlg : TTP2005PrintDialog;
     bin : Integer;
    begin
     PrtDlg:=TMyPrintDialog.Create(Self, CimReport1.r_id.AsInteger);
     frxReport1.PrintOptions.ShowDialog:=False;
     If PrtDlg.ShowModal=mrOk then
         ....
     //Kopie 1
     frxReport1.PrintOptions.Printer:=PrtDlg.PrintersCB.Text;
      Bin:=frxPrinters.Printer.BinNameToNumber(PrtDlg.bin_copie_1.Text);
      TfrxHackedPrinter(frxPrinters.Printer).Bin:=bin;
      frxReport1.Print//direktes Drucken
    
    info339 wrote: »
    hello,
    how can i use my own printer dialog
    i have same skins and there can not design the fastreport printerdialog
    many thx for any tip

    my poor code for FR-Printdialog is ...
    //the report is ok
    frxReport1.Print ;


    //now my windows-printdialog
    //how can i the printdialog tranfer the report??
    printdialog1.execute;

    ciao
    info339

Leave a Comment