hiding blank image fields in a report (1 Viewer)

Bharathi1977

New member
Local time
Today, 17:30
Joined
Dec 8, 2014
Messages
5
Hi all,
My student is doing a project on question paper generation in which he selects questions from each lesson needed and also some of these questions have images associated with them. So, if these questions are selected, the image control in the report displays it. If there is no image, the space for the control is left in tact. I tried changing the visible property for the image control in the Detail_Format event procedure. But this code is not reached at all and the space is still left. I am not storing the image directly in the field but its path in a text field.
I want that the space occupied by the image control removed. I tried the suppression thing but obviously it did not work. I hope I get some help in here.
Thanks in advance

Bharathi:banghead:
 

llkhoutx

Registered User.
Local time
Today, 07:00
Joined
Feb 26, 2001
Messages
4,018
Shrink the height to the same as the rest of the relative row and then set it Can Grow / Can Shrink property to Yes.
 

Bharathi1977

New member
Local time
Today, 17:30
Joined
Dec 8, 2014
Messages
5
Thank you llkhoutx.
The image control I put on the form takes the source from the image field in the table and I dont see the can grow/can shrink properties in the format property list of the image box.
Is there any other solution for this problem?
 

llkhoutx

Registered User.
Local time
Today, 07:00
Joined
Feb 26, 2001
Messages
4,018
I was referring to a report control property, not a table column property.
 

Never Hide

Registered User.
Local time
Today, 15:00
Joined
Dec 22, 2011
Messages
96
i know this is an old thread and I don't know if you found a solution,if yes please mark it as Solved, but just in case.
Try using the report's Open event instead. Check if the path for the image is empty and if it is set the Visible value of the image control to false
 

Bharathi1977

New member
Local time
Today, 17:30
Joined
Dec 8, 2014
Messages
5
Hi Never Hide,
I have done it and it doesn't seem to work. The events in the report are not even reached. I have tried changing the image box attributes in the Report Open event as well as the Detail Format event. None of it is working. I think my questioning was wrong.
I have an image field which contains the path of the image as it makes the database size larger if we store images in it. In the report, if the image field contains a path, the image is filled in the box. The report has to be exported to rtf and the worst part is that graphics are not exported into rtf. If I export in pdf, I can't remove extra spaces that are formed because it is non-editable. I am in a fix with this. No amount of property changing is working for this situation.

Any help is appreciated. I am on a deadline for this month-end.
 

Bharathi1977

New member
Local time
Today, 17:30
Joined
Dec 8, 2014
Messages
5
Hi All,
Happy to say that my problem is solved. Instead of trying to make the image box size smaller (after a long fight with it), I settled on mail merging into Word. I put up some macros and some vba code to get it done and it is working good. Thank you all for the patience and support.
 

Users who are viewing this thread

Top Bottom