PrintInBackground...
Do you have any examples where you use the PrintInBackground method.
I'm trying to use this method so that no windows are displayed. I'm
using the following code:
ArcReport.ShowCancelDialog:= False;
ArcReport.ShowPrintDialog:= False;
ArcReport.DeviceType:= dtArchive;
ArcReport.AllowPrintToArchive:= True;
ArcReport.ShowAutoSearchDialog:= False;
ArcReport.ArchiveFileName := 'd:\ArchTest.raf';
ArcReport.PrintInBackground;
I keep getting the same error:
EInvlidOperation: "Canvas does not allow drawing."
This error is followed by:
TppBackgroundPringThread.PrintInBackground: Ten second timeout
exceeded for background printing thread to create report container.
Am I forgetting to set another property? Do you have any examples
where this method is used?
Thanks,
Mike
I'm trying to use this method so that no windows are displayed. I'm
using the following code:
ArcReport.ShowCancelDialog:= False;
ArcReport.ShowPrintDialog:= False;
ArcReport.DeviceType:= dtArchive;
ArcReport.AllowPrintToArchive:= True;
ArcReport.ShowAutoSearchDialog:= False;
ArcReport.ArchiveFileName := 'd:\ArchTest.raf';
ArcReport.PrintInBackground;
I keep getting the same error:
EInvlidOperation: "Canvas does not allow drawing."
This error is followed by:
TppBackgroundPringThread.PrintInBackground: Ten second timeout
exceeded for background printing thread to create report container.
Am I forgetting to set another property? Do you have any examples
where this method is used?
Thanks,
Mike
This discussion has been closed.
Comments
form/datamodule threadsafe?
Is your TppReport's Owner a TForm or TDatamodule? It should not be nil if
you are creating it dynamically.
Here are some projects which show how to extend the behavior of the
background printing:
http://www.digital-metaphors.com/tips/BackgroundPrintDemos.zip
If you still can't get it to work, then send a simple example to
support@digital-metaphors.com
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com