Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

load dynamic image from path in crystal report

I want to show an image in my report , I save path of image in my sqlserver database and now I want to load image from path .I search all of internet for that and try all of guidance , I first insert image into my report and after that I go to >Format Editor > picture > Graphic Location > and insert path of image into the textarea like this {Command.path} but when I run , it doesn't show any picture . Now how should I do ?
I use visual studio 2013 and latest version of crystal report .

like image 823
amin Avatar asked Oct 27 '25 06:10

amin


1 Answers

Use a conditional formula to dynamically change the location of a report’s image.

  1. Add an image to the report: -> Insert -> Picture This image will act as a placeholder. Ensure that the placeholder is the same size as the one that will be dynamically loaded, otherwise, the image will be scaled.

  2. Change the image’s Graphic Location:
    -> right click image
    -> select Format Graphic…
    -> select Picture tab
    -> click the conditional-formula button (looks like x+2)
    -> set the formula’s text to the name of the formula or parameter field that will contain the image’s URL
    -> save the formula and click the OK button
    -> save the report

It worked for me.

Source: cogniza.com

like image 68
Khalid Shifullah Porag Avatar answered Oct 29 '25 22:10

Khalid Shifullah Porag



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!