Advertisement

There's no such thing as a stupid question, but they're the easiest to answer.
Login
Search

Advertisement

Search Search
Search for:
Tech Support Guy > > >

Access 2010 cancel sub report


(!)

draceplace's Avatar
draceplace   (Dan) draceplace is offline
Computer Specs
Member with 1,802 posts.
THREAD STARTER
 
Join Date: Jun 2001
Location: Conway, Arkansas
06-Jul-2012, 01:22 PM #1
Access 2010 cancel sub report
I've got a sub report that displays the 'CC:'s" for a letter if they are entered on a form. When there is no data in the CC textboxes the sub report still displays the "CC:" label on the letter. I want to suppress that. I've tried these.

Private Sub Report_Load()
If Me.Text78 Is Null Then
Me.Label44.Visible = False
End Sub

Where text78 is the first CC entry on the (sub)report (from the CC textbox of the form).

Private Sub Report_NoData(Cancel As Integer)
Cancel = True
End Sub

Anybody know this one?
OBP's Avatar
OBP OBP is offline OBP is a Trusted Advisor with special permissions.
Computer Specs
Trusted Advisor with 18,538 posts.
 
Join Date: Mar 2005
Location: UK
06-Jul-2012, 01:29 PM #2
You want to use the Subreport's "On No Data" event procedure to make the field or subform invisible.
As Seen On

BBC, Reader's Digest, PC Magazine, Today Show, Money Magazine
WELCOME TO TECH SUPPORT GUY!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.


Tags
access, report, vba code

(clock)
THIS THREAD HAS EXPIRED.
Are you having the same problem? We have volunteers ready to answer your question, but first you'll have to join for free. Need help getting started? Check out our Welcome Guide.

Search Tech Support Guy

Find the solution to your
computer problem!




Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools


WELCOME
You Are Using: Server ID
Trusted Website Back to the Top ↑