Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > Report Control
  New Posts New Posts RSS Feed - Page numbers not showing up in print preview
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Page numbers not showing up in print preview

 Post Reply Post Reply
Author
Message
Mike Lewis View Drop Down
Groupie
Groupie


Joined: 29 April 2009
Status: Offline
Points: 41
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mike Lewis Quote  Post ReplyReply Direct Link To This Post Topic: Page numbers not showing up in print preview
    Posted: 14 September 2009 at 4:29am
I'm using the ActiveX Report Control, version 13.1.

I'm trying to print "Page x of y" in the footer of a printed report. I have set PrintOptions.Footer.TextLeft  to "Page &p of &P".

In both the printout and the preview, these characters are interpreted literally, that is, the control actually prints "Page &p of &P". Can anyone tell me what I should do to have these characters interpreted as page number and no. of pages? Everything else in print preview seems to be working OK.

Thanks in advance.

Mike
Mike Lewis
Software Developer
Edinburgh, Scotland
Back to Top
joeliner View Drop Down
Senior Member
Senior Member
Avatar

Joined: 09 June 2006
Status: Offline
Points: 273
Post Options Post Options   Thanks (0) Thanks(0)   Quote joeliner Quote  Post ReplyReply Direct Link To This Post Posted: 14 September 2009 at 7:28am
Hi,
 
Try
 
.footer.FormatString = "Page &p of &P"
 
regards
Product: Xtreme SuitePro (ActiveX) version 13.1
Platform: Windows XP SP 3
Language: Visual Basic 6 SP6
Back to Top
Mike Lewis View Drop Down
Groupie
Groupie


Joined: 29 April 2009
Status: Offline
Points: 41
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mike Lewis Quote  Post ReplyReply Direct Link To This Post Posted: 14 September 2009 at 8:35am
Joeliner, you've delivered the good yet again. It works perfectly. Thanks.

Now, is there any way to specify that the footer will appear to the left, right or centre (like you can with Footer.TextLeft, etc)?

Mike
Mike Lewis
Software Developer
Edinburgh, Scotland
Back to Top
joeliner View Drop Down
Senior Member
Senior Member
Avatar

Joined: 09 June 2006
Status: Offline
Points: 273
Post Options Post Options   Thanks (0) Thanks(0)   Quote joeliner Quote  Post ReplyReply Direct Link To This Post Posted: 14 September 2009 at 8:44am
Hi
 
try
 
Reportcontrol.Printoptions.footer.FormatString = "Copyright" & " &b &b " & "Pages  &p of &P"
 
regards,
 
Joel
Product: Xtreme SuitePro (ActiveX) version 13.1
Platform: Windows XP SP 3
Language: Visual Basic 6 SP6
Back to Top
Mike Lewis View Drop Down
Groupie
Groupie


Joined: 29 April 2009
Status: Offline
Points: 41
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mike Lewis Quote  Post ReplyReply Direct Link To This Post Posted: 14 September 2009 at 8:47am
Many thanks, Joel. That's exactly what I needed.

Mike
Mike Lewis
Software Developer
Edinburgh, Scotland
Back to Top
mdoubson View Drop Down
Senior Member
Senior Member
Avatar

Joined: 17 November 2008
Status: Offline
Points: 1705
Post Options Post Options   Thanks (0) Thanks(0)   Quote mdoubson Quote  Post ReplyReply Direct Link To This Post Posted: 15 September 2009 at 8:33pm
Guys - I was sure that this simple tag set (like &p, &D...) presented in documentation.
Back to Top
Mike Lewis View Drop Down
Groupie
Groupie


Joined: 29 April 2009
Status: Offline
Points: 41
Post Options Post Options   Thanks (0) Thanks(0)   Quote Mike Lewis Quote  Post ReplyReply Direct Link To This Post Posted: 16 September 2009 at 2:21am
Mark,

I found the spec for .TextLeft, etc. in the Help, but I didn't think to look for .FormatString. I discovered the use of &p etc. by looking at the dialogue (the one produced by .ShowPrintPageSetup).

As always, the information was present in the documentation, but I had no way of knowing where to find it.

Mike
Mike Lewis
Software Developer
Edinburgh, Scotland
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.218 seconds.