Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Page Numbering a report with vba

Status
Not open for further replies.

RonMcIntire

Technical User
Oct 12, 2002
166
US
I have written a routine to add the page number of a report in the footer section. The routine populates a textbox control so that I get this: =" - " & [Page]+13 & " - " .

How do I preview the report with the page number? This entails calling the routine before the report previews but I don't know how.

Anyone have any ideas? The answer is simple, I think.
Ron
 
Are you adding 13 to the page number? or are you trying to do something like Page 1 of 13?
 
Writing the 13 images to a report is solved. This 13 is a report start page.

Right now I can write the =" - " & [Page]+1 & " - " statement to the footer and make it print on the page when the report prints. Under normal circumstances, the statement must enter the report in design mode to make it work. It may not be possible.
 
So you are starting at Page 13...I'll have to dig around in an older db I have where I did something like that some time ago. May not get back to you until Monday.
 
After some more research, my question boils down to: Can I write code containing an Access object to a report that is in design mode? If I can, my problem is solved - if I knew how. Any thoughts?
 
Sorry for delay. Wasn't sure why you need to have the code alter the design mode. see if what I posted in your other thread helps your issue.

Adding variables to a control in a footer
thread703-1813895
 
Ron,
Is your value always 13 or do you want to make it dynamic?
Can we assume your "report in the footer section" is a page footer section?

Duane
Minnesota
Hook'D on Access
MS Access MVP 2001-2016
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top