Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Wrong page numbering (Page 32 of 31) in MS Access 2003

Posted on 2014-01-31
5
Medium Priority
?
342 Views
Last Modified: 2014-03-20
I have a report which is generated from MS Access 2003.  It has existed for many years but now the page numbering has started to go wrong showing up as page 32 of 31.  There are no blank pages in the report.

The report is made up of a
Report Header
Page Header
GroupHeader 1 (this section contains a sub-report)
GroupHeader 2
GroupHeader 3 (this section contains a sub-report)
Detail
GroupFooter3
PageFoot (this is where the Page of Pages is located)
ReportFooter


The two sub-reports display images and are resized in code to match the current image.

Can anyone suggest what might be causing this behaviour and how I can fix it.
0
Comment
Question by:Nemetona
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 15

Expert Comment

by:JimFive
ID: 39824126
Is there any VBA code in any of the Section's Format events?  It looks to me like something is being miscalculated due to a "Retreat".  When the report is getting formatted the format event can run multiple times if it would flow over to a new page.  This causes a Retreat and then a new Format.  If something is Calculating either the current page or the max pages manually this would cause it to be in error.
0
 
LVL 58
ID: 39824150
I was going to ask the same thing; do you have any code that is adjusting the page numbers?

 You can avoid the retreat issue by making sure your checking the format/print count (depends which event your in) with:

 If FormatCount = 1 then
       Me.Page = 1
 End If

Jim.
0
 

Author Comment

by:Nemetona
ID: 39824167
I am using the MS Access in-built [Page] and [Pages] fields to determine the number of pages.

The detail format section in the sub-report within the subreport on the GroupHeader1 section does run 3 times for each page but no calculation of current page or max page takes place.
0
 
LVL 58

Accepted Solution

by:
Jim Dettman (Microsoft MVP/ EE MVE) earned 2000 total points
ID: 39824209
<<The two sub-reports display images and are resized in code to match the current image.>>

 This is the issue....where are you doing the resizing?  Because of this, you may have to handle the page numbering yourself.

Jim.
0
 

Author Closing Comment

by:Nemetona
ID: 39942711
Jim

You were right, the problem lay in the resizing of the pictures, once I sorted that out the page numbering took care of itself.
0

Featured Post

Get free NFR key for Veeam Availability Suite 9.5

Veeam is happy to provide a free NFR license (1 year, 2 sockets) to all certified IT Pros. The license allows for the non-production use of Veeam Availability Suite v9.5 in your home lab, without any feature limitations. It works for both VMware and Hyper-V environments

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Traditionally, the method to display pictures in Access forms and reports is to first download them from URLs to a folder, record the path in a table and then let the form or report pull the pictures from that folder. But why not let Windows retr…
If you need a simple but flexible process for maintaining an audit trail of who created, edited, or deleted data from a table, or multiple tables, and you can do all of your work from within a form, this simple Audit Log will work for you.
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question