Defining a compound Footer

P

Peter Rooney

I'm trying to define a footer in VBA that will display the values of two
variables, "StartDate" and "EndDate" within the following:

FilePageSetupFooter Text:="Page &[Page] of &[Pages] & [date]"

If I include [StartDate] and [Endate] like this within the footer string thus:

FilePageSetupFooter Text:="[StartDate] [EndDate] Page &[Page] of &[Pages] &
[date]"

all I get is the words printed out in brackets (which is what I'd expect, as
they're not reserved fields in the same way as Page], [Pages] etc.

I tried to create a compound string containing my variable names, and
substitute it into the ...text: = command, but then I couldn't reference
[Page], [Pages] correctly!

I want my string to say "Resource Usage Print from aa/aa/aa to bb/bb/bb Page
1 of cc dd/dd/dd"

where:

aa/aa/aa is my variable StartDate
bb/bb/bb is my variable EndDate
cc is [Pages]
dd/dd/dd is [Date]

Also, could somebody please put me straight on the correct syntax to use
when changing fonts and font sizes within a footer string - I think I'm using
too many sets of quotes!

Thanks in advance

Pete
 
J

Jan De Messemaeker

Text="Begin of the text " & cstr(whateverstartdate) & " mid text " &
cstr(whateverenddate) & " end of text"
HTH
 
P

Peter Rooney

Jan,

Thanks very much - this works fine!

Could you help me out one more time, though - I'm now trying to alter the
font size and name for the footer, but I can't seem to get the &16 and the
&""Impact"" in the right place. This is what I have so far:

FilePageSetupFooter Text:="Resource Usage Print for " & CStr(StartDate) & "
- " & CStr(EndDate) & " Page &[Page] of &[Pages] & [date]"

Thanks in advance

Pete

HTBH

(On the basis that HTH means "Happy To Help", this is "Happy To BE Helped""!)

Jan De Messemaeker said:
Text="Begin of the text " & cstr(whateverstartdate) & " mid text " &
cstr(whateverenddate) & " end of text"
HTH
--
Jan De Messemaeker
Microsoft Project Most Valuable Professional
http://users.online.be/prom-ade/index.htm
32-495-300 620
Peter Rooney said:
I'm trying to define a footer in VBA that will display the values of two
variables, "StartDate" and "EndDate" within the following:

FilePageSetupFooter Text:="Page &[Page] of &[Pages] & [date]"

If I include [StartDate] and [Endate] like this within the footer string thus:

FilePageSetupFooter Text:="[StartDate] [EndDate] Page &[Page] of &[Pages] &
[date]"

all I get is the words printed out in brackets (which is what I'd expect, as
they're not reserved fields in the same way as Page], [Pages] etc.

I tried to create a compound string containing my variable names, and
substitute it into the ...text: = command, but then I couldn't reference
[Page], [Pages] correctly!

I want my string to say "Resource Usage Print from aa/aa/aa to bb/bb/bb Page
1 of cc dd/dd/dd"

where:

aa/aa/aa is my variable StartDate
bb/bb/bb is my variable EndDate
cc is [Pages]
dd/dd/dd is [Date]

Also, could somebody please put me straight on the correct syntax to use
when changing fonts and font sizes within a footer string - I think I'm using
too many sets of quotes!

Thanks in advance

Pete
 
J

Jan De Messemaeker

Hi Peter,

Don't remember the right text fromteh help but I found this snippet that
actually works:

FilePageSetupHeader _
Alignment:=pjCenter, _
Text:=("&B&14 " & Title_Text)

HTH

--
Jan De Messemaeker
Microsoft Project Most Valuable Professional
http://users.online.be/prom-ade/index.htm
32-495-300 620
Peter Rooney said:
Jan,

Thanks very much - this works fine!

Could you help me out one more time, though - I'm now trying to alter the
font size and name for the footer, but I can't seem to get the &16 and the
&""Impact"" in the right place. This is what I have so far:

FilePageSetupFooter Text:="Resource Usage Print for " & CStr(StartDate) & "
- " & CStr(EndDate) & " Page &[Page] of &[Pages] & [date]"

Thanks in advance

Pete

HTBH

(On the basis that HTH means "Happy To Help", this is "Happy To BE Helped""!)

Jan De Messemaeker said:
Text="Begin of the text " & cstr(whateverstartdate) & " mid text " &
cstr(whateverenddate) & " end of text"
HTH
--
Jan De Messemaeker
Microsoft Project Most Valuable Professional
http://users.online.be/prom-ade/index.htm
32-495-300 620
"Peter Rooney" <[email protected]> schreef in bericht
I'm trying to define a footer in VBA that will display the values of two
variables, "StartDate" and "EndDate" within the following:

FilePageSetupFooter Text:="Page &[Page] of &[Pages] & [date]"

If I include [StartDate] and [Endate] like this within the footer
string
thus:
FilePageSetupFooter Text:="[StartDate] [EndDate] Page &[Page] of
&[Pages]
&
[date]"

all I get is the words printed out in brackets (which is what I'd
expect,
as
they're not reserved fields in the same way as Page], [Pages] etc.

I tried to create a compound string containing my variable names, and
substitute it into the ...text: = command, but then I couldn't reference
[Page], [Pages] correctly!

I want my string to say "Resource Usage Print from aa/aa/aa to
bb/bb/bb
Page
1 of cc dd/dd/dd"

where:

aa/aa/aa is my variable StartDate
bb/bb/bb is my variable EndDate
cc is [Pages]
dd/dd/dd is [Date]

Also, could somebody please put me straight on the correct syntax to use
when changing fonts and font sizes within a footer string - I think
I'm
using
too many sets of quotes!

Thanks in advance

Pete
 
P

Peter Rooney

Jan,

I took your suggestion, and after much messing around, came up with the
following which sets the text to 36 point italic underline bold Impact (how
many attributes can I add?)

FilePageSetupHeader Text:=("&I&U&B&""Impact""&36" & CStr(HeaderString))

Thanks again!

Pete


Jan De Messemaeker said:
Hi Peter,

Don't remember the right text fromteh help but I found this snippet that
actually works:

FilePageSetupHeader _
Alignment:=pjCenter, _
Text:=("&B&14 " & Title_Text)

HTH

--
Jan De Messemaeker
Microsoft Project Most Valuable Professional
http://users.online.be/prom-ade/index.htm
32-495-300 620
Peter Rooney said:
Jan,

Thanks very much - this works fine!

Could you help me out one more time, though - I'm now trying to alter the
font size and name for the footer, but I can't seem to get the &16 and the
&""Impact"" in the right place. This is what I have so far:

FilePageSetupFooter Text:="Resource Usage Print for " & CStr(StartDate) & "
- " & CStr(EndDate) & " Page &[Page] of &[Pages] & [date]"

Thanks in advance

Pete

HTBH

(On the basis that HTH means "Happy To Help", this is "Happy To BE Helped""!)

Jan De Messemaeker said:
Text="Begin of the text " & cstr(whateverstartdate) & " mid text " &
cstr(whateverenddate) & " end of text"
HTH
--
Jan De Messemaeker
Microsoft Project Most Valuable Professional
http://users.online.be/prom-ade/index.htm
32-495-300 620
"Peter Rooney" <[email protected]> schreef in bericht
I'm trying to define a footer in VBA that will display the values of two
variables, "StartDate" and "EndDate" within the following:

FilePageSetupFooter Text:="Page &[Page] of &[Pages] & [date]"

If I include [StartDate] and [Endate] like this within the footer string
thus:

FilePageSetupFooter Text:="[StartDate] [EndDate] Page &[Page] of &[Pages]
&
[date]"

all I get is the words printed out in brackets (which is what I'd expect,
as
they're not reserved fields in the same way as Page], [Pages] etc.

I tried to create a compound string containing my variable names, and
substitute it into the ...text: = command, but then I couldn't reference
[Page], [Pages] correctly!

I want my string to say "Resource Usage Print from aa/aa/aa to bb/bb/bb
Page
1 of cc dd/dd/dd"

where:

aa/aa/aa is my variable StartDate
bb/bb/bb is my variable EndDate
cc is [Pages]
dd/dd/dd is [Date]

Also, could somebody please put me straight on the correct syntax to use
when changing fonts and font sizes within a footer string - I think I'm
using
too many sets of quotes!

Thanks in advance

Pete
 
J

Jan De Messemaeker

Good, Pete.
Thanks for the positive feedback.
--
Jan De Messemaeker
Microsoft Project Most Valuable Professional
http://users.online.be/prom-ade/index.htm
32-495-300 620
Peter Rooney said:
Jan,

I took your suggestion, and after much messing around, came up with the
following which sets the text to 36 point italic underline bold Impact (how
many attributes can I add?)

FilePageSetupHeader Text:=("&I&U&B&""Impact""&36" & CStr(HeaderString))

Thanks again!

Pete


Jan De Messemaeker said:
Hi Peter,

Don't remember the right text fromteh help but I found this snippet that
actually works:

FilePageSetupHeader _
Alignment:=pjCenter, _
Text:=("&B&14 " & Title_Text)

HTH

--
Jan De Messemaeker
Microsoft Project Most Valuable Professional
http://users.online.be/prom-ade/index.htm
32-495-300 620
"Peter Rooney" <[email protected]> schreef in bericht
Jan,

Thanks very much - this works fine!

Could you help me out one more time, though - I'm now trying to alter the
font size and name for the footer, but I can't seem to get the &16 and the
&""Impact"" in the right place. This is what I have so far:

FilePageSetupFooter Text:="Resource Usage Print for " &
CStr(StartDate) &
"
- " & CStr(EndDate) & " Page &[Page] of &[Pages] & [date]"

Thanks in advance

Pete

HTBH

(On the basis that HTH means "Happy To Help", this is "Happy To BE Helped""!)

:

Text="Begin of the text " & cstr(whateverstartdate) & " mid text " &
cstr(whateverenddate) & " end of text"
HTH
--
Jan De Messemaeker
Microsoft Project Most Valuable Professional
http://users.online.be/prom-ade/index.htm
32-495-300 620
"Peter Rooney" <[email protected]> schreef in bericht
I'm trying to define a footer in VBA that will display the values
of
two
variables, "StartDate" and "EndDate" within the following:

FilePageSetupFooter Text:="Page &[Page] of &[Pages] & [date]"

If I include [StartDate] and [Endate] like this within the footer string
thus:

FilePageSetupFooter Text:="[StartDate] [EndDate] Page &[Page] of &[Pages]
&
[date]"

all I get is the words printed out in brackets (which is what I'd expect,
as
they're not reserved fields in the same way as Page], [Pages] etc.

I tried to create a compound string containing my variable names, and
substitute it into the ...text: = command, but then I couldn't reference
[Page], [Pages] correctly!

I want my string to say "Resource Usage Print from aa/aa/aa to bb/bb/bb
Page
1 of cc dd/dd/dd"

where:

aa/aa/aa is my variable StartDate
bb/bb/bb is my variable EndDate
cc is [Pages]
dd/dd/dd is [Date]

Also, could somebody please put me straight on the correct syntax
to
use
when changing fonts and font sizes within a footer string - I
think
I'm
using
too many sets of quotes!

Thanks in advance

Pete
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top