Board index » delphi » Closing a QR preview before the preview is finished generating

Closing a QR preview before the preview is finished generating

I am using Delphi 4.03 and QR 3.08 with a custom preview form.  If I preview
a report and then click to close the preview before the report is finished
generating I get an Access violation error.  I have followed all the
examples from QR regarding the custom previews and in fact I have the exact
same code in my OnClose event of my preview form as they do.  Example:

procedure TfrmPrintPreview.FormClose(Sender: TObject; var Action:
TCloseAction);
begin
   QRPrinter.ClosePreview(Self);
   Action := caFree;
end;

I've tried Application.ProcessMessages before and after the ClosePreview
call and nothing seems to work.  Does anyone have any suggestions or tricks
that will work?

--
Scott Slater

 

Re:Closing a QR preview before the preview is finished generating


hi,

I remember i had the same problem.
Then i downloaded the example preview from Qusoft and i didn't have the
problem anymore.

--
Nicchi Roberto
MASTER INFORMATICA
Hardware & Software House
AREZZO, ITALY

Re:Closing a QR preview before the preview is finished generating


Well I have the standard preview that comes with QR and I'm doing things
exactly as it does.  I'll go up the their web site and see if there is
something else to look at.  Thanks!
--
Scott Slater

Quote
"Roberto Nicchi" <softw...@masterinformatica.net> wrote in message

news:Xns91BC744D7AEF5softwaremasterinform@207.105.83.65...
Quote
> hi,

> I remember i had the same problem.
> Then i downloaded the example preview from Qusoft and i didn't have the
> problem anymore.

> --
> Nicchi Roberto
> MASTER INFORMATICA
> Hardware & Software House
> AREZZO, ITALY

Other Threads