Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Texas_Toast
 
Posts: n/a
Default Can custom headers be linked to a cell in the worksheet?

This was a feature in 123 where header or footer information could be
retrieved from a cell in the worksheet. Is there anything similar in Excel?
  #2   Report Post  
Dave Peterson
 
Posts: n/a
Default

You could use a macro...

For instance, this code goes behind the ThisWorkbook module:

Option Explicit
Private Sub Workbook_BeforePrint(Cancel As Boolean)
With Worksheets("sheet1")
.PageSetup.LeftHeader = .Range("a1").Text
End With
End Sub



Texas_Toast wrote:

This was a feature in 123 where header or footer information could be
retrieved from a cell in the worksheet. Is there anything similar in Excel?


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.misc
Pam in California
 
Posts: n/a
Default Can custom headers be linked to a cell in the worksheet?

I'm trying to enter this marco, and need some clarification as I am having
some trouble with with macro.
With Worksheets("sheet 1"), sheet 1 would be the worksheet that contains
the information, and the range "a1" is the cell, correct? My worksheet name
is Expense Worksheet. Do I need to change the worksheet name to
Expense_Worksheet?

I would like the text in cell a1, which is my e7, to be in the header on all
7 of my worksheets - is this possible?

I hope this makes sense. Thanks for your help.
-pam


"Dave Peterson" wrote:

You could use a macro...

For instance, this code goes behind the ThisWorkbook module:

Option Explicit
Private Sub Workbook_BeforePrint(Cancel As Boolean)
With Worksheets("sheet1")
.PageSetup.LeftHeader = .Range("a1").Text
End With
End Sub



Texas_Toast wrote:

This was a feature in 123 where header or footer information could be
retrieved from a cell in the worksheet. Is there anything similar in Excel?


--

Dave Peterson

  #4   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson
 
Posts: n/a
Default Can custom headers be linked to a cell in the worksheet?

You would change this:

With Worksheets("sheet1")
to
With Worksheets("Expense Worksheet")
(It has to match exactly.)

(It really is named "expense worksheet"??)





Pam in California wrote:

I'm trying to enter this marco, and need some clarification as I am having
some trouble with with macro.
With Worksheets("sheet 1"), sheet 1 would be the worksheet that contains
the information, and the range "a1" is the cell, correct? My worksheet name
is Expense Worksheet. Do I need to change the worksheet name to
Expense_Worksheet?

I would like the text in cell a1, which is my e7, to be in the header on all
7 of my worksheets - is this possible?

I hope this makes sense. Thanks for your help.
-pam

"Dave Peterson" wrote:

You could use a macro...

For instance, this code goes behind the ThisWorkbook module:

Option Explicit
Private Sub Workbook_BeforePrint(Cancel As Boolean)
With Worksheets("sheet1")
.PageSetup.LeftHeader = .Range("a1").Text
End With
End Sub



Texas_Toast wrote:

This was a feature in 123 where header or footer information could be
retrieved from a cell in the worksheet. Is there anything similar in Excel?


--

Dave Peterson


--

Dave Peterson
  #5   Report Post  
Posted to microsoft.public.excel.misc
Pam in California
 
Posts: n/a
Default Can custom headers be linked to a cell in the worksheet?

So my macro would look like this:
Option Explicit
Private Sub Workbook_BeforePrint(Cancel As Boolean)
With Worksheets ("Expense_Worksheet")
.PageSetup.LeftHeader = .Range("e7").Text
End With
End Sub

Sorry to be dense on this. The header isn't pulling the information from e7
so I think I haven't done this properly.
-pam

"Dave Peterson" wrote:

You would change this:

With Worksheets("sheet1")
to
With Worksheets("Expense Worksheet")
(It has to match exactly.)

(It really is named "expense worksheet"??)





Pam in California wrote:

I'm trying to enter this marco, and need some clarification as I am having
some trouble with with macro.
With Worksheets("sheet 1"), sheet 1 would be the worksheet that contains
the information, and the range "a1" is the cell, correct? My worksheet name
is Expense Worksheet. Do I need to change the worksheet name to
Expense_Worksheet?

I would like the text in cell a1, which is my e7, to be in the header on all
7 of my worksheets - is this possible?

I hope this makes sense. Thanks for your help.
-pam

"Dave Peterson" wrote:

You could use a macro...

For instance, this code goes behind the ThisWorkbook module:

Option Explicit
Private Sub Workbook_BeforePrint(Cancel As Boolean)
With Worksheets("sheet1")
.PageSetup.LeftHeader = .Range("a1").Text
End With
End Sub



Texas_Toast wrote:

This was a feature in 123 where header or footer information could be
retrieved from a cell in the worksheet. Is there anything similar in Excel?

--

Dave Peterson


--

Dave Peterson



  #6   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson
 
Posts: n/a
Default Can custom headers be linked to a cell in the worksheet?

Does that worksheet name have a space between words or an underscore?

Expense_Worksheet
or
Expense Worksheet

You have to match it exactly the way you see it on the tab itself.



Pam in California wrote:

So my macro would look like this:
Option Explicit
Private Sub Workbook_BeforePrint(Cancel As Boolean)
With Worksheets ("Expense_Worksheet")
.PageSetup.LeftHeader = .Range("e7").Text
End With
End Sub

Sorry to be dense on this. The header isn't pulling the information from e7
so I think I haven't done this properly.
-pam

"Dave Peterson" wrote:

You would change this:

With Worksheets("sheet1")
to
With Worksheets("Expense Worksheet")
(It has to match exactly.)

(It really is named "expense worksheet"??)





Pam in California wrote:

I'm trying to enter this marco, and need some clarification as I am having
some trouble with with macro.
With Worksheets("sheet 1"), sheet 1 would be the worksheet that contains
the information, and the range "a1" is the cell, correct? My worksheet name
is Expense Worksheet. Do I need to change the worksheet name to
Expense_Worksheet?

I would like the text in cell a1, which is my e7, to be in the header on all
7 of my worksheets - is this possible?

I hope this makes sense. Thanks for your help.
-pam

"Dave Peterson" wrote:

You could use a macro...

For instance, this code goes behind the ThisWorkbook module:

Option Explicit
Private Sub Workbook_BeforePrint(Cancel As Boolean)
With Worksheets("sheet1")
.PageSetup.LeftHeader = .Range("a1").Text
End With
End Sub



Texas_Toast wrote:

This was a feature in 123 where header or footer information could be
retrieved from a cell in the worksheet. Is there anything similar in Excel?

--

Dave Peterson


--

Dave Peterson


--

Dave Peterson
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
In Cell Validation List & Linked Cell VLOOKUP BEEZ Excel Discussion (Misc queries) 7 July 1st 07 07:17 PM
Why does Custom Format not control Cell Display? Dennis Excel Discussion (Misc queries) 1 June 11th 05 12:28 AM
How do I format a cell for a custom part number? PJ Excel Discussion (Misc queries) 4 March 3rd 05 03:57 AM
Copying linked cell references. Shams Excel Worksheet Functions 0 February 3rd 05 01:53 PM
Date on two lines using a custom cell format possible? .:mmac:. Excel Discussion (Misc queries) 5 December 4th 04 09:41 PM


All times are GMT +1. The time now is 09:36 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"