LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 24
Default CenterHeader, RightHeader, LeftHeader

I have the following code:

With Worksheets("Report").PageSetup
.RightHeader = xRightHeader
.CenterHeader = xCenterHeader
.LeftHeader = xLeftHeader
End With

The xVariables are defined and populated just prior to this code.

I get the following error: Run-time error '1004' "Unable to set the
LeftHeader property of the PageSetup class".

If I swap the code around like this:

With Worksheets("Report").PageSetup
.RightHeader = xRightHeader
.CenterHeader = xCenterHeader
.LeftHeader = xLeftHeader
End With

I get: Run-time error '1004' "Unable to set the RightHeader property of the
PageSetup class".

If I remove either the right, the left or the center, the code works fine.
Is there some kind of limitation that prevents us from setting all three of
the headers?

Ross


 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Enter Multiple lines using .leftheader Carol Excel Discussion (Misc queries) 0 June 5th 07 05:23 PM
Using VBA to insert a multiple-row title in the CenterHeader Montana Excel Programming 2 October 18th 06 03:02 PM
Setting LeftHeader / CenterHeader MBaas Excel Programming 3 August 17th 06 04:56 PM
Pagesetup. Is there no way to control the LeftMargin of the LeftHeader ? Claus[_3_] Excel Programming 5 September 9th 05 07:56 AM
Excel generation and PageSetup.CenterHeader lfb Excel Programming 3 February 9th 04 05:24 PM


All times are GMT +1. The time now is 01:34 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"