Reputation: 499
In SSRS Report, we have a requirement where we need to show or hide the images in the footer based on the Boolean parameters. We have three images icon with image source assigned. We are displaying the images in the right corner horizontally aligned next to each other. All the images are coming correctly as long as if I get 'Visible' True for all the images.
But if I get visible false for any image, I am getting blank space since I assigned fixed width to the images.
Is there any way to dynamically create image source or reduce the width of the image in the expression, so that I can avoid displaying empty space in the middle.
Upvotes: 0
Views: 1094
Reputation: 499
Found a work-around to this. This is what i implemented
I have added 3 images in the footer section [right aligned]
Created a dataset with 3 columns Image1, Image2 and Image3. Written a custom query to fill this columns. If 2 images configured in Website, updated first 2 columns with image names. if only one image configured in website update the Image1 column and leave others empty.
Assign the image sources for the footer images from the dataset. Order should be left to right and source should be Image1, Image2 and Image3.
So if all 3 columns have the values, it will display all the images. If any 2 images are configured, then it will assign sources to the right most 2 images and leave the third one empty. So I am not facing any empty space issue in between if the image is not available. Now the system is capable of showing the images dynamically based on the availability.
Upvotes: 2
Reputation: 2156
Upvotes: 0