Results 1 to 6 of 6
  1. #1
    2 Star Lounger
    Join Date
    Jun 2005
    Location
    Atlanta, Georgia, USA
    Posts
    208
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Report Footer (2003)

    I have a report built that when there is no data the fields in the footer shows error in the fields. Is there a way that would show a text box that says "no data" and hiding those other text boxes with the error message that are in the footer? thanks

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Report Footer (2003)

    You could use an IIf expression that uses HasData to check whether the report has data:

    =IIf([HasData],...,"No Data")

    where ... is the expression that you want to display if there are data.

    Alternatively, you can use the On Format event of the report footer to hide/unhide controls.

  3. #3
    2 Star Lounger
    Join Date
    Jun 2005
    Location
    Atlanta, Georgia, USA
    Posts
    208
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Report Footer (2003)

    thanks

  4. #4
    2 Star Lounger
    Join Date
    Jun 2005
    Location
    Atlanta, Georgia, USA
    Posts
    208
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Report Footer (2003)

    On the On Format event of the footer, I am not sure of the code that would go there. I have fields that return no values and I have tried and iif statement with is null and tried to set to visible.false but doesn't work. Are there any other ways to do this? Thanks.

  5. #5
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Report Footer (2003)

    The code would look like this, with the appropriate names substituted:
    <code>
    Private Sub ReportFooter_Format(Cancel As Integer, FormatCount As Integer)
    Me.txtThis.Visible = Not IsNull(Me.txtThis)
    Me.txtThat.Visible = Not IsNull(Me.txtThat)
    Me.txtOther.Visible = Not IsNull(Me.txtOther)
    End Sub</code>

  6. #6
    2 Star Lounger
    Join Date
    Jun 2005
    Location
    Atlanta, Georgia, USA
    Posts
    208
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Report Footer (2003)

    Thanks it is now working

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •