Once the preview form has been created you can access the Report.PreviewForm.Icon property to change the icon of the preview form. The best place to do this is in the Report.OnPreviewFormCreate event.
looks for the icon when you preview the report. Is there a way to store the icon as part of the program .exe (so it does not look for the icon on the c: drive)?
You can also use the published property TppReport.Icon property to load an icon file and store it in the report's .dfm file essentially embedding the .ico file inside the application.
Sorry if I was confusing. If you place a TppReport object on a form and select it, you can access the Icon property from the Delphi Object Inspector. From there you can load an .ico file which will then be embedded into your .dfm or Form file so there will be no need to load the icon image from file again. Hope this helps.
Comments
Once the preview form has been created you can access the
Report.PreviewForm.Icon property to change the icon of the preview form.
The best place to do this is in the Report.OnPreviewFormCreate event.
--
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
using
rbMyReport.PreviewForm.Icon.LoadFromFile('C:\MyIcon.ico');
looks for the icon when you preview the report. Is there a way to
store the icon as part of the program .exe (so it does not look for
the icon on the c: drive)?
thanking you
You can also use the published property TppReport.Icon property to load an
icon file and store it in the report's .dfm file essentially embedding the
.ico file inside the application.
--
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
where do I run this from? its a bit over my head. Do you have an
example.
thanking you Nico
Sorry if I was confusing. If you place a TppReport object on a form and
select it, you can access the Icon property from the Delphi Object
Inspector. From there you can load an .ico file which will then be embedded
into your .dfm or Form file so there will be no need to load the icon image
from file again. Hope this helps.
--
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
thank you Nico