Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 174
  • Last Modified:

Need to display the text "NO DATA" on a report that has no records

My user wants to have the replace say "No Data" on it when there are no records to report, not just get a message that no data is available, they need an actual report that indicates so.  So, how do I change the underlying query for the report when there is no data to report on?
0
ssmith94015
Asked:
ssmith94015
  • 2
  • 2
1 Solution
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
You want a 'No Data' message to appear on the report ?

mx
0
 
Rey Obrero (Capricorn1)Commented:
create a label with caption "NO DATA", set visible property to NO

in the report Nodata event show the label

private sub Report_NoData(Cancel As Integer)

Me.lblNoData.Visible = True
End Sub

0
 
ssmith94015Author Commented:
Yes, I need a message on the report that indicates there is no data for the report.  I am going to try Cap's suggestion.  Be right back.
0
 
ssmith94015Author Commented:
Cap. works perfectly.  
0
 
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database ArchitectCommented:
Cap post the exact code I would have posted lol.

mx
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now