1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

Access 2010 cancel sub report

Discussion in 'Business Applications' started by draceplace, Jul 6, 2012.

Thread Status:
Not open for further replies.
Advertisement
  1. draceplace

    draceplace Thread Starter

    Joined:
    Jun 8, 2001
    Messages:
    2,056
    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?
     
  2. OBP

    OBP Trusted Advisor

    Joined:
    Mar 8, 2005
    Messages:
    18,834
    You want to use the Subreport's "On No Data" event procedure to make the field or subform invisible.
     
As Seen On
As Seen On...

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.

Join over 733,556 other people just like you!

Loading...
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/1059939