Report tppImage in Service Application don't print the image
Hello,
I have a Service (Tservice) who print a report (with an Image in a
TppImage component) and sent it via mail; all works fine until I try to
load the report from a template with the ppReport1.Template.LoadFromFile.
In this case all the text and shapes are printed correctly, but the image
disappear from the print and from the mail (print saved into pdf file and
then sended with Indy component as attachment).
I tried to set the DirectDraw flag to True value on tppImage component but
nothing happens.
Can someone help me?
Thanks.
Cristiano
--- posted by geoForum on http://delphi.newswhat.com
I have a Service (Tservice) who print a report (with an Image in a
TppImage component) and sent it via mail; all works fine until I try to
load the report from a template with the ppReport1.Template.LoadFromFile.
In this case all the text and shapes are printed correctly, but the image
disappear from the print and from the mail (print saved into pdf file and
then sended with Indy component as attachment).
I tried to set the DirectDraw flag to True value on tppImage component but
nothing happens.
Can someone help me?
Thanks.
Cristiano
--- posted by geoForum on http://delphi.newswhat.com
This discussion has been closed.
Comments
Which version of ReportBuilder and Delphi are you using?
Does this only occur when using the service? If you load the report from
template in a simple test application, are you able to see the image when
printing? How is the image loaded into the TppImage object?
--
Regards,
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
I'm using the delphi 2006 with reportbuilder 10.70.
Yes this happens only in the Service Application. The report is used in a
desktop application and it's ok, if I load the report dinamically it's
printed normally.
Yes in the test application I see the report, and the image, both in
preview and in print.
The image is a Jpg Image.
If i don't load dinamically the report it's printed right in the service
application but i need to load dinamically the report becouse I can have
many types of report (with the same fields) and logos.
Thanks in advance.
Cristiano.
Cristiano
--- posted by geoForum on http://delphi.newswhat.com
ReportBuilder Server can load reports from .rtm that contain images, so it
definitely works. RB Server can run as a Windows Service and is
multi-threaded.
Check that the Service App has included ppJPEG in the uses clause.
--
Nard Moseley
Digital Metaphors
www.digital-metaphors.com
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com
Thanks Nard,
I solved the problem. Now the report print fine, I set the following
properties to false (the first 4 are already false, but the remaining 2
are setted to true) and now all the images are printed correctly.
ppReport1.ModalPreview := False;
ppReport1.ModalCancelDialog := False;
ppReport1.AllowPrintToFile := False;
ppReport1.ShowPrintDialog := False;
ppReport1.ShowCancelDialog := False;
ppREport1.ShowAutoSearchDialog := False;
Thanks.
Cristiano.
Cristiano
--- posted by geoForum on http://delphi.newswhat.com