By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,829 Members | 670 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,829 IT Pros & Developers. It's quick & easy.

How to Not Print invisible Subreports

P: 44
Hi

I have a Report made up of 8 Subreports for Knitting Instructions for knitting Garment parts such as Body, Sleeves, Collar, Bands. However, some garments do not have a collar (i.e. a Vee Necked cardigan), so I don't want this subreport to print.

I have made the Subreport invisible, but I still get a blank page where that subreport should appear.

How do I tell it not to print the invisible subreport, and not to leave a space where that subreport would print if it were visible.

I cannot use the Property for No Data, as there is data on the report (a field stating that the Collar Type = N/A, and an OLE picture of the Vee Band, showing why the Collar is Not Applicable). I just don't want to have to print that data.

Many thanks for your ideas

Viv.
Dec 24 '08 #1
Share this Question
Share on Google+
5 Replies


nico5038
Expert 2.5K+
P: 3,072
Easiest way is to make the height of the subreport as less as possible (just one line) than make sure the "CanGrow" property is set to "Yes" and you're in business :-)

Nic;o)
Dec 24 '08 #2

P: 44
Thanks Nico - That works fine.

However, as I am a complete beginner with VBA and am on a very steep learning curve, how would I tell it not to print the invisible subreport using code?

Viv
Dec 24 '08 #3

nico5038
Expert 2.5K+
P: 3,072
Hi Viv,

Check out: http://bytes.com/topic/access/answer...b-report-blank
Instead of the Null (or 0) code there you would need to check or the sub report's query doesn't return records.

Nic;o)
Dec 24 '08 #4

P: 44
Thanks Nico. Could not get the code to run without the same Error Message as your last person. However, Report is now doing exactly as I want, not showing Subreports where there is no Collar or Bands.

Thanks again.
Viv
Dec 24 '08 #5

nico5038
Expert 2.5K+
P: 3,072
Glad I could help, success with your application !

Nic;o)
Dec 24 '08 #6

Post your reply

Sign in to post your reply or Sign up for a free account.