In the attached DB I have a Report whose some sections have NO Data. I have written code in ReportAmtISum, ReportAmtFSum, ReportAmtMSum to indicate NIL, but it is not working. Kindly guide me as to what I should do.
In the attached DB I have a Report whose some sections have NO Data. I have written code in ReportAmtISum, ReportAmtFSum, ReportAmtMSum to indicate NIL, but it is not working. Kindly guide me as to what I should do.
Put your code in the OnFormat event of the "Detail" section of the report.
If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
Bob Fitzpatrick
You will have to do it for each sub reports detail on format section.
The other option is to hide the sub report using the on NoData property.
Again this would have to be set for each report / sub-report as each section does not know about the others results.
DLookup Syntax and others http://access.mvps.org/access/general/gen0018.htm
Please use the star below the post to say thanks if we have helped !
↓↓ It's down here ↓↓
"Doesn't work" means what - error message, wrong result, nothing happens? Post attempted code.
One-liner:
Me.Label7.Visible = IsNull(Me.SumOfAMOUNT)
Be aware Format event does not run for ReportView.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
Sorry, Sir! I had put the code in top level report. I have corrected the mistake and placed your one-liner on the lowest report containing the 2 controls. I am enclosing the file for you to view. Thanks a lot! GOD BLESS YOU!!! One humble request plese brief me about the ON FORMAT event.
You put code in Format event? What do you need to know? Did you Google for more info?
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
I would like to know about the other option of hiding the sub-reports having no data.
Suggest you Google for info. Make an effort in that direction and when you have specific issue post question.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.
Format event fires for PrintPreview and direct to printer, not for ReportView.
How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.