|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| ||||||||||||||||||||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Spreadsheet_excel_writer and headers/footers
Hi,
Is there somebody who could document the setHeader and setFooter functions? I would like to be able to set the left/right header and footer but can't seem to find out how. I was also wondering if it is possible to print excel constants like &[Page], &[Pages], &[Date], &[Time] or also &[File]. Thank you |
|
#2
|
|||
|
|||
|
RE: Spreadsheet_excel_writer and headers/footers
I'm not sure how to set the left or right headers. I have figured out how to set the constants that Excel allows you to use in Headers and Footers though. Use the following codes in your strings:
Code:
&a = &[Tab] = Tab Name &d = &[Date] = Date &f = &[File] = File Name &n = &[Pages] = Total # of Pages &p = &[Page] = Page Number &t = &[Time] = Time &w = &[Path] = Working Directory (Path) An example would be: Code:
$worksheet->setFooter('Page &p of &n');
I'm not sure if this is officially supported (can't find anything about it), but it seems to work on my machine with Excel 2003 and Spreadsheet_excel_writer version 0.9.1 |
|
#3
|
|||
|
|||
|
RE: Spreadsheet_excel_writer and headers/footers
Thank you that works perfectly.
For the left/right header you can use the same kind of delimiter &L for Left header &C for Center header &R for Right header ex. $worksheet->setHeader('&LConfidential&C&f&RPage &p of &n'); Thank you |
![]() |
| Viewing: Codewalkers Forums > PHP Related > PEAR Packages > Spreadsheet_excel_writer and headers/footers |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|