Advertisement

05.08.2008 at 01:41PM PDT, ID: 23387620 | Points: 250
[x]
Attachment Details
How do you force "GroupHeader1" to always display even if the Detail section is has no data for some recorders?
Tags: Microsoft, Office, 2007, report header display
In Access 2007, I want a header to appear for all records even if there's no data for the detail section of my report.  I only have one field in the detail section, named Action & I tried the following code, but it didn't make the header appear for all records.

Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
    If IsNull([Action]) Then
       Me![GroupHeader1].Visible = True
    End If
End Sub
Start your free trial to view this solution
Question Stats
Zone: Microsoft
Question Asked By: leslieinva
Question Asked On: 05.08.2008
Participating Experts: 3
Points: 250
Views: 0
Translate:
Loading Advertisement...
05.08.2008 at 01:55PM PDT, ID: 21528403

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 02:59PM PDT, ID: 21528826

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 03:22PM PDT, ID: 21528958

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 03:32PM PDT, ID: 21529017

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 03:35PM PDT, ID: 21529037

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 03:50PM PDT, ID: 21529111

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 03:56PM PDT, ID: 21529137

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 04:10PM PDT, ID: 21529203

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 04:20PM PDT, ID: 21529266

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 09:27PM PDT, ID: 21530393

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 09:36PM PDT, ID: 21530417

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 11:50PM PDT, ID: 21530789

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.15.2008 at 07:11AM PDT, ID: 21573802

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.15.2008 at 10:23AM PDT, ID: 21576078

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
 
Loading Advertisement...
Microsoft
  • Internet Protocols
  • Applications
  • Development
  • OS
  • Hardware
  • Windows Security
Apple
  • Operating Systems
  • Hardware
  • Programming
  • Networking
  • Software
Internet
  • Search Engines
  • File Sharing
  • WebTrends / Stats
  • Spy / Ad Blockers
  • Web Browsers
  • New Net Users
  • Web Development
  • Chat / IM
  • Anti Spam
  • Web Servers
  • Anti-Virus
  • Email Clients
Gamers
  • Tips
  • Online / MMORPG
  • Puzzle
  • Emulators
  • Action / Adventure
  • Role Playing
  • Consoles
  • Game Programming
  • Strategy
  • Sports
  • Misc
  • Computer Games
Digital Living
  • Hardware
  • New Net Users
  • New Users
  • Software
  • Digital Music
  • Gaming World
  • Home Security
  • Apple
  • Networking Hardware
Virus & Spyware
  • Vulnerabilities
  • IDS
  • Encryption
  • Anti-Virus
  • Operating Systems Security
  • Software Firewalls
  • WebApplications
  • Cell Phones
  • Operating Systems
  • Internet
  • Hardware Firewalls
Hardware
  • Handhelds / PDAs
  • Displays / Monitors
  • Components
  • Networking Hardware
  • Peripherals
  • Laptops/Notebooks
  • Storage
  • Servers
  • Desktops
  • New Users
  • Misc
  • Apple
Software
  • System Utilities
  • Industry Specific
  • Network Management
  • Photos / Graphics
  • Page Layout
  • VMWare
  • Misc
  • Web Development
  • OS
  • CYGWIN
  • Voice Recognition
  • Message Queue
  • Quality Assurance
  • Security
  • Firewalls
  • MultiMedia Applications
  • Development
  • Database
  • Office / Productivity
  • Business Management
  • OS/2 Apps
  • Server Software
  • Internet / Email
ITPro
  • OS
  • Storage
  • Encryption
  • Operating Systems Security
  • Apple Hardware
  • Laptops & Notebooks
  • Servers
  • Networking Hardware
  • Peripherals
  • Devices
  • Displays / Monitors
  • WebTrends / Stats
  • Search Engines
  • Firewalls
  • WebApplications
  • IDS
  • Vulnerabilities
  • Email Clients
  • File Sharing
  • Spy / Ad Blockers
  • Web Browsers
  • Web Servers
  • Networking
  • Anti-Virus
  • Chat / IM
  • Anti Spam
Developer
  • Web Servers
  • Web Browsers
  • Game Programming
  • Dev Tools
  • Industry Specific
  • Office / Productivity
  • Database
  • CYGWIN
  • Web Development
  • Search Engines
  • File Sharing
  • WebTrends / Stats
  • Programming
  • Content Management
  • Application Servers
  • Protocols
Storage
  • Removable Backup Media
  • Storage Technology
  • Servers
  • Grid
  • Remote Access
  • Backup / Restore
  • Misc
  • Hard Drives
OS
  • Miscellaneous
  • Security
  • Development
  • Linux
  • VMWare
  • MainFrame OS
  • Unix
  • Apple
  • OS / 2
  • AS / 400
  • BeOS
  • Microsoft
  • VMS / OpenVMS
Database
  • Oracle
  • Miscellaneous
  • MySQL
  • Software
  • Sybase
  • Contact Management
  • PostgreSQL
  • Data Manipulation
  • Clarion
  • InterSystems Cache
  • Siebel
  • MUMPS
  • OLAP
  • SQLBase
  • SAS
  • GIS & GPS
  • 4GL
  • Berkeley DB
  • DB2
  • Informix
  • Interbase / Firebird
  • FoxPro
  • Reporting
  • LDAP
  • Filemaker Pro
  • MS SQL Server
  • dBase
  • MS Access
Security
  • Misc
  • Web Browsers
  • Software Firewalls
  • Operating Systems Security
  • File Sharing
  • Spy / Ad Blockers
  • Vulnerabilities
  • WebApplications
  • IDS
  • Anti-Virus
  • Encryption
  • Anti Spam
  • Email Clients
  • VPN
  • Chat / IM
Programming
  • Editors IDEs
  • Installation
  • Handhelds / PDAs
  • Multimedia Programming
  • System / Kernel
  • Algorithms
  • Game
  • Signal Processing
  • Project Management
  • Open Source
  • Database
  • Misc
  • Languages
  • Processor Platforms
  • Theory
Web Development
  • Scripting
  • Blogs
  • Web Servers
  • Software
  • Search Engines
  • Web Graphics
  • Images
  • Internet Marketing
  • Images and Photos
  • Components
  • Document Imaging
  • Web Languages/Standards
  • Illustration
  • WebApplications
  • Fonts
  • WebTrends / Stats
  • Authoring
  • Digital Camera Software
  • Miscellaneous
Networking
  • Protocols
  • Apple Networking
  • Network Management
  • Message Queue
  • Application Servers
  • Content Management
  • File Servers
  • Email Servers
  • Misc
  • Java Editors & IDEs
  • Wireless
  • Networking Hardware
  • Backup / Restore
  • System Utilities
  • ISPs & Hosting
  • Web Servers
  • Storage Technology
  • Removable Backup Media
  • Servers
  • Broadband
  • Grid
  • OS / 2
  • Novell Netware
  • Unix Networking
  • Windows Networking
  • Security
  • Telecommunications
  • Operating Systems
  • Linux Networking
Other
  • Community Advisor
  • Lounge
  • Community Support
  • New Net Users
  • Philosophy / Religion
  • Math / Science
  • Miscellaneous
  • URLs
  • Expert Lounge
  • Politics
  • Puzzles / Riddles
Community Support
  • Suggestions
  • New to EE
  • New Topics
  • Community Advisor
  • CleanUp
  • Announcements
  • General
  • Feedback
  • Input
  • EE Bugs
 
05.08.2008 at 01:55PM PDT, ID: 21528403

Rank: Genius

The Header should be there whether or not there a records in the Detail section.
 
05.08.2008 at 02:59PM PDT, ID: 21528826

Rank: Master

I don't even think you have to do any special code. Check the header properties. Make sure the "Can Shrink" property is set to No. If that doesn't work, I would simply add an clear / transparent object in the header so that it always stay open,.
 
05.08.2008 at 03:22PM PDT, ID: 21528958

Rank: Genius

TT ... how you been?

leslieinva

The header really should be there, regardless of detail data or not.  In fact, I just confirmed this to be absolutely sure.

mx
 
05.08.2008 at 03:32PM PDT, ID: 21529017

Rank: Master

I am fine Leslie. Thanks for asking. I've just been really busy at work lately.

In any event, so are you saying that in the case where there is no data in the detail section, the header disappears? Sort of dynamically displaying and hiding the header based on the detail section?
 
05.08.2008 at 03:35PM PDT, ID: 21529037

Rank: Genius

It was me MX (not Leslie) asking how you are :-)

mx
 
05.08.2008 at 03:50PM PDT, ID: 21529111

Rank: Master

Sorry about MX. How are you? It has been a while, hasn't it.
 
05.08.2008 at 03:56PM PDT, ID: 21529137

Rank: Genius

lol ... yes ... A while.  It's all good here.

mx
 
05.08.2008 at 04:10PM PDT, ID: 21529203

Rank: Master

MX - I see you are racking up some serious points. I need to get back in the game. :-) I'm after cap's records. Just kidding.

Leslie - As MX stated, the header should always be there regardless of the Detail section results. I just checked it myself and it works fine.
 
05.08.2008 at 04:20PM PDT, ID: 21529266

Rank: Genius

Yes ... get serious and get back in the game :-)

mx
 
05.08.2008 at 09:27PM PDT, ID: 21530393

Rank: Genius

If you want to see group headers for groups without details, you need to build a special query for this.

Let's imagine you want products grouped by categories, making sure every category is listed even if there are no products.

    SELECT Products.*, Categories.CategoryName
    FROM Categories LEFT JOIN Products ON Categories.CatID = Products.CatID

By using LEFT JOIN, you will have one record for every category, with all the "product" fields being Null if there are no products. With such a Record Source, you will have all the headers for the group "CategoryName", and you can use code to determine what to do with a detail section having Nulls everywhere.

Good luck!
(°v°)
 
05.08.2008 at 09:36PM PDT, ID: 21530417

Rank: Genius

"If you want to see group headers for groups without details, you need to build a special query for this."

Well, I don't think that is always the case.  As a test, I have an Employee table ... which besides the EmpID, it has an EmpIDRptsToID ... which is another Employee in the table of course ... the 'self join' idea.  So, lets say that a 'supervisor' does not have anyone reporting to them at this time.  In the report, if I GroupBy RptsToID/Name ... then, I get a Header for that 'supervisor', but there are no detail records.  Of course, that employee (supervisor) will may show up under a header with *no group name* ... as an employee with no reports to.

So ... that is the test I referenced above.  There is only one table here ... and the Header with no details (employees reporting to this supervisor) shows up with no problem.

mx
 
05.08.2008 at 11:50PM PDT, ID: 21530789

Rank: Genius

> lets say that a 'supervisor' does not have anyone reporting to them at this time.

That would mean that no record has the number 11 (the 'supervisor' ID) in the field EmpIDPrtsToID. If you group the table by that field, there will be no group 11, hence no group header for that person, even if he/she is a potential supervisor.

If your report is based on a query, it's different, of course: Employees as supervisors left joined on employees as subordinates on supervisor's ID equal to subordinate's reports to ID...

(°v°)
 
05.15.2008 at 07:11AM PDT, ID: 21573802
I had three tables linked together for the recordsource of the report.  I'm not sure why it wouldn't put on header, but I solved it by using a subreport instead.
 
05.15.2008 at 10:23AM PDT, ID: 21576078

Rank: Genius

Instead of deleting, just Accept your own answer - and leave the info here for others.

mx
 
 
20080236-EE-VQP-29 / EE_QW_2_20070628