Solved Help with label on report! (1 Viewer)

slharman1

Member
Local time
Today, 06:46
Joined
Mar 8, 2021
Messages
467
I have a label on my report called accessories, and it prints below every item just before the accessories sub report data prints.
What I need to do is not print it if the item does not contain any accessories.
Can anyone help me out with this one?
 

theDBguy

I’m here to help
Staff member
Local time
Today, 04:46
Joined
Oct 29, 2018
Messages
21,358
Sounds like you might need to use the Print event to make the label visible or invisible.
 

slharman1

Member
Local time
Today, 06:46
Joined
Mar 8, 2021
Messages
467
Sounds like you might need to use the Print event to make the label visible or invisible.
Not sure how to do that. I am using a cmdButton to print a report based on the selected re it’s of a continuous form.
 

theDBguy

I’m here to help
Staff member
Local time
Today, 04:46
Joined
Oct 29, 2018
Messages
21,358
Not sure how to do that. I am using a cmdButton to print a report based on the selected re it’s of a continuous form.
I am referring to the Print event on the Report. That way, it doesn't matter how you open the report, it will always evaluate whether to show or hide the label. If you want to see an example, consider posting a sample copy of your db with test data (and the report you're trying to modify, of course).
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 07:46
Joined
Feb 19, 2002
Messages
42,981
Use the on Format event of the report's detail section to check to see if the subreport would have data and hide it if there is no data.
 

slharman1

Member
Local time
Today, 06:46
Joined
Mar 8, 2021
Messages
467
Use the on Format event of the report's detail section to check to see if the subreport would have data and hide it if there is no data.
Thanks all! Pat it was even easier than that. I just moved the label from the main report to the sub report and that did it.
 

Users who are viewing this thread

Top Bottom