Load Picture to picture object during runtime

How to load a picture during runtime. Are there any function to retrieve the
path of the program?

I've tried the following:
Picture1.LoadFromFile('Config\picture1.jpg');

This works only if the current path is set to my program path

Juergen

Comments

  • gordkgordk St.Catherines On. Canada.
    edited 12:20AM
    either pass the path into the report as a variable when loading or
    use te report components onbefore print event.
    ;)
  • dschuchdschuch Dresden,Germany
    edited 12:20AM
    Yes,

    in Delphi :

    frxReport1.Variables:=''''+ExtractFilePath(ParamStr(0))+'''';

    in FR :

    Picture1.LoadFromFile(<MainPath>+'picture1.jpg');

    Daniel
  • edited 12:20AM
    Thanks a lot Daniel.
    I thought that there are predefined variables/functions
    in the script itself.

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.