Aspose::Cells::PageSetup::SetHeader method
Contents
[
Hide
]PageSetup::SetHeader(int32_t, const U16String&) method
Sets a script formatting the header of an Excel file.
void Aspose::Cells::PageSetup::SetHeader(int32_t section, const U16String &headerScript)
| Parameter | Type | Description |
|---|---|---|
| section | int32_t | 0: Left Section, 1: Center Section, 2: Right Section. |
| headerScript | const U16String& | Header format script. |
Remarks
Script commands:
| Command | Description |
|---|---|
| &P | Current page number |
| &N | Page count |
| &D | Current date |
| &T | Current time |
| &A | Sheet name |
| &F | File name without path |
| &"<FontName>" | Font name, for example: &"Arial" |
| &"<FontName>, <FontStyle>" | Font name and font style, for example: &"Arial,Bold" |
| & | Font size. If this command is followed by a plain number to be printed in the header, it will be separated from the font height with a space character. |
| &K | Font color, for example(RED): &KFF0000 |
| &G | Image script |
- Class Vector
- Class U16String
- Class PageSetup
- Namespace Aspose::Cells
- Library Aspose.Cells for C++
PageSetup::SetHeader(int32_t, const char16_t*) method
Sets a script formatting the header of an Excel file.
void Aspose::Cells::PageSetup::SetHeader(int32_t section, const char16_t *headerScript)
| Parameter | Type | Description |
|---|---|---|
| section | int32_t | 0: Left Section, 1: Center Section, 2: Right Section. |
| headerScript | const char16_t* | Header format script. |
Remarks
Script commands:
| Command | Description |
|---|---|
| &P | Current page number |
| &N | Page count |
| &D | Current date |
| &T | Current time |
| &A | Sheet name |
| &F | File name without path |
| &"<FontName>" | Font name, for example: &"Arial" |
| &"<FontName>, <FontStyle>" | Font name and font style, for example: &"Arial,Bold" |
| & | Font size. If this command is followed by a plain number to be printed in the header, it will be separated from the font height with a space character. |
| &K | Font color, for example(RED): &KFF0000 |
| &G | Image script |
- Class Vector
- Class PageSetup
- Namespace Aspose::Cells
- Library Aspose.Cells for C++