i have an access data base that generates questions and some of them have pictures for the question that have no pictures i have an empty space is there a way to get the lable to disapear when there is no picture so i dont have this huge empty gap in between
report image resize when there is an image or not
Collapse
X
-
glatif,
I'm not sure exactly how you have your report built, but there may be some options. If the picture is all by itself on a horizontal space, then simply make the height of the image control 0, but the CanGrow property to Yes. Then, in the OnFormat Event of the report, check for the existence of an image. If there is an image, set the image control to that image and adjust the height. This will "push" all other controls on the report down.
Hope this makes sense. But, we can work through the details if not. -
thanks for the reply twinnyfo my report is basicly an exam creator so when you select the exam you want to print it will give you multiple choises question and some of them have a picture so for the CanGrow i have a OLEunbound Picture fram and that dosent have that option what do i have to use to get this working because i only found the lable that have the option CanGrow and when i attache the i give it the controle source of the image database it just brings me back numbersComment
-
here is a screen shot of my report if could helpAttached FilesComment
-
Use an Image control.
And..... I spoke incorrectly. I thought the image control had a CanGrow property but it does not. Never fear, I've skinned many a cat in my life and developed many ways to do so.
Another option would be to create a separate header in which the only thing you place is the image control. Again, use the OnFormat Event for the header to determine if there is an image. Then, if there is, adjust the height of the header and the image control appropriately.
I think it may be a few extra steps, but should accomplish what you want to do.Comment
-
thanks again for the response but i tried to do it unless its me that is doind something wrong but it not working the problem is that my report containes something like 30 questions and only maybe 5 have a picture for them when i do the headder i still see the same thingComment
Comment