I am not able to load two different images dynamically in an Image control

HI,

Base on pagenumber, i need to display a particular image in first page and another image in next page.

there are two images and has to be displayed alternatively in the pages.

but, it is displaying only one image everytime.

I am using Exteranl and URL based concept and using parameters to pass the values from the front end to the report

One more thing I did was, I place two image controls and passing the URL through two parameters having the URL as the value.

but still the both the image controls display only one image.




Answer this question

I am not able to load two different images dynamically in an Image control

  • Barbfrog

    it should be possible to use expression to show image conditionally.

    set image value property to expression, for example, for URL image:

    =iif(<Some condition>,
    "
    http://localhost/Reports/images/48folderopen.jpg",
    "
    http://localhost/Reports/images/16prop.gif")



  • dseverojr

    Hi,

    I am using an expression.

    One more thing I am getting the path thru the Parameters.

    I have two different Paths one for customer logo and another is company logo

    and i have used the parameters in iif conditon.

    example: iif((Globals!PageNumber) Mod 2 = 0,Parameters!RgLogoPath.Value,Parameters!CustLogoPath.Value)

    one more thing i tried is

    place two image controls in Page Header and in the Value i used expression and for both the images i gave Parameters!RgLogoPath.Value and Parameters!CustLogoPath.Value respectively. when i saw the preview , only one image was displayed in both image controls



  • CGSReddy

    Is this happening in page headers only Does it work differently if put in the report body

  • I am not able to load two different images dynamically in an Image control