Skip to Content

Display an image in crystal report that retrieve from folder in c#

I want to display specific images located in a folder inside the project. I want to display it in a crystal report(dynamically). trying to insert an image as OLE object >> right click then format object >> choose picture tab >> click on a graphic location and write the following line:


but didn't work. Again, I don't need to retrieve the path from the database, I need to retrieve images from the folder which I created. How can I achieve that? Thanks in advance.

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    Posted on Apr 03 at 03:22 PM

    Your expression ({Application.StartupPath\images\1.jpg}) is not a valid Crystal syntax.

    As sanity check, first create a formula that returns the path to the file. Place it on the report canvas and preview to confirm it returns a valid path. Then, use that formula in the Graphic Location expression.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Apr 02 at 06:07 PM

    CR and SDK will only load the file on Open, it cannot be used to update the image at runtime.

    You need to use a formula field or database field that specifies the file location.

    Only way it's going to update at runtime

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.