Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 45
Default finding pure pageheader text???

I need to read the contents of the left pageheader - no problem:

Titel = ActiveSheet.PageSetup.LeftHeader


Problem occur if the users has change the format of the text!

That way I might get something like this:

Titel = "&""Times New Roman,Bold""&12Expenses 2008"


How to only read the pure text of the header?
(In this case: "Expenses 2008")


Problem is that I cannot know what font, format or size (if any) the user
might have given the header!

Can someone help my???


Thanks,


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,986
Default finding pure pageheader text???

If you only want to view the headers and footers, then:

Sub viewHeader()
MsgBox ActiveSheet.PrintPreview
End Sub

However, you can do this manually in Excel. Otherwise, the header/footer
information is returned in code form when called with the constants
LeftHeader, RightHeader, etc. If you enter header or footer data in clear
text, it will return clear text. Otherwise, you would have to return the
variable value for the text you want to display.

"Charlotte E." wrote:

I need to read the contents of the left pageheader - no problem:

Titel = ActiveSheet.PageSetup.LeftHeader


Problem occur if the users has change the format of the text!

That way I might get something like this:

Titel = "&""Times New Roman,Bold""&12Expenses 2008"


How to only read the pure text of the header?
(In this case: "Expenses 2008")


Problem is that I cannot know what font, format or size (if any) the user
might have given the header!

Can someone help my???


Thanks,



Reply
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
Pure .NET Office add-in vs VSTO solutions dizzy Excel Programming 1 November 30th 07 12:49 PM
a code to trace pure numbers formatted as Text swordsman Excel Programming 4 September 3rd 07 11:28 PM
R6025 pure virtual funtion call Jerry Excel Discussion (Misc queries) 0 February 9th 07 08:37 PM
pageheader size ermeko Excel Programming 3 May 4th 05 04:43 PM
Formatting a cell in Excel, using pure VB code Jean Claude Excel Programming 4 October 2nd 03 05:41 PM


All times are GMT +1. The time now is 04:12 AM.

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

About Us

"It's about Microsoft Excel"