Board index » cppbuilder » QR Custom Preview

QR Custom Preview

Hi
I have read the documents to make my own custom preview report for all
my reports.  Therefore I have:

//---------------------------------------------------------------------
void __fastcall TForm1::ShowPreview()
{
  FormPreview->ShowModal();

Quote
}

//--------------------------------------------
The above code on Form1.

QRPrinter->OnPreview = ShowPreview;
when we have on show of Form1

so that when i want to see a preview form i have:
        Form2->QuickReport2->Preview();

However, the errors apperar:

*****    ShowPreview is not a member of TForm1  *****

Can anyone help solve this?

 

Re:QR Custom Preview


Sorry I can't help you but I have seen an Preview-example to download by
qusoft.
Perhaps is this helpful vor you.

http://www.qusoft.no/scripts/download.dll

File: CUSTPREV.ZIP

j.t.sincl...@cableinet.co.uk schrieb in Nachricht
<3778CA9A.4...@cableinet.co.uk>...

Quote
>Hi
>I have read the documents to make my own custom preview report for all
>my reports.  Therefore I have:

>//---------------------------------------------------------------------
>void __fastcall TForm1::ShowPreview()
>{
>  FormPreview->ShowModal();
>}
>//--------------------------------------------
>The above code on Form1.

>QRPrinter->OnPreview = ShowPreview;
>when we have on show of Form1

>so that when i want to see a preview form i have:
> Form2->QuickReport2->Preview();

>However, the errors apperar:

>*****    ShowPreview is not a member of TForm1  *****

>Can anyone help solve this?

Re:QR Custom Preview


in the on preview event of the report

void __fastcall TfrmRepSalary::QuickRep1Preview(TObject *Sender)
{
  frmRepPreview = new TfrmRepPreview(this);
  frmRepPreview->QRPreview1->QRPrinter = (TQRPrinter*)Sender;
  frmRepPreview->Show();

Quote
}

and create your custom report form with a qrpreview object on it...

Quote
j.t.sincl...@cableinet.co.uk wrote in message

<3778CA9A.4...@cableinet.co.uk>...
Quote
>Hi
>I have read the documents to make my own custom preview report for all
>my reports.  Therefore I have:

>//---------------------------------------------------------------------
>void __fastcall TForm1::ShowPreview()
>{
>  FormPreview->ShowModal();
>}
>//--------------------------------------------
>The above code on Form1.

>QRPrinter->OnPreview = ShowPreview;
>when we have on show of Form1

>so that when i want to see a preview form i have:
> Form2->QuickReport2->Preview();

>However, the errors apperar:

>*****    ShowPreview is not a member of TForm1  *****

>Can anyone help solve this?

Other Threads