Image scaling to fit width

Stimulsoft Reports.NET discussion
Post Reply
Tobias
Posts: 102
Joined: Mon Nov 24, 2008 8:44 am

Image scaling to fit width

Post by Tobias »

I would like to have an image in a databand (loaded from the data source) which is always scaled to fit the whole width of the databand and to grow/shrink vertically to keep the original aspect ratio.

The image is set to "Stretch=True" and "Aspect Ratio=True". Image and databand are set to CanGrow/CanShrink=True. What happens is, that as soon as I set CanGrow=True, the image grows beyond (!) the databand width and also results in new pages beeing created.

I've attached a simple example.

Is this a bug, am I doing something wrong or is this simply not possible at all?
Attachments
Report.mrt
(18.63 KiB) Downloaded 152 times
Lech Kulikowski
Posts: 6245
Joined: Tue Mar 20, 2018 5:34 am

Re: Image scaling to fit width

Post by Lech Kulikowski »

Hello,

Please try to set the MaxSize property.

If the issue still present, please send us a sample which result you need.

Thank you.
Tobias
Posts: 102
Joined: Mon Nov 24, 2008 8:44 am

Re: Image scaling to fit width

Post by Tobias »

This doesn't work either. If I set the MaxSize.Width, then the image is correctly scale to the width, but somehow I end up with a lot of vertically free space after the image.
See attachment.
Attachments
Report.pdf
(49.52 KiB) Downloaded 389 times
Report.mrt
(18.71 KiB) Downloaded 163 times
Lech Kulikowski
Posts: 6245
Joined: Tue Mar 20, 2018 5:34 am

Re: Image scaling to fit width

Post by Lech Kulikowski »

Hello,

We need some additional time to investigate the issue.

Try to set the MaxSize-Height property also.

Thank you.
Post Reply