PrintHeader Property
See Also DLL Example 1 Example 2
Applies To
fpSpread control
Description
Sets or returns the text and format of headers on printed pages. This property is available at run time only.
Syntax
CString CSpreadSheet::GetPrintHeader( );
void CSpreadSheet::SetPrintHeader(LPCTSTR value);
[form.]fpSpread.PrintHeader[ = text$]
Remarks
Use the PrintHeader property to specify the text to appear as a header on the printed pages. You can also customize the position and appearance of the header text by using control characters.
Use the control characters before the text that you want to customize. If you use multiple control characters, do not put spaces between them. The following control characters are available:
Control Character | Description |
---|---|
/n | New line |
/l | Left aligns text |
/r | Right aligns text |
/c | Centers text |
/cl | Sets text forecolor |
/date | Adds current date |
/dl | Adds current date in long date format |
/ds | Adds current date in short date format |
/time | Adds current time |
/tl | Adds current time in long date format |
/ts | Adds current time in short date format |
/p | Inserts page number |
/pc | Inserts page count |
// | Prints a slash character (/) |
/fn | Font name, must be enclosed in quotes |
/fz | Font size in points, must be enclosed in quotes |
/fb0 | Font bold off |
/fb1 | Font bold on |
/fi0 | Font italics off |
/fi1 | Font italics on |
/fu0 | Font underline off |
/fu1 | Font underline on |
/fk0 | Font strikethrough off |
/fk1 | Font strikethrough on |
/fs1 | Saves the current font configuration as configuration 1 |
/fs2 | Saves the current font configuration as configuration 2 |
/fs3 | Saves the current font configuration as configuration 3 |
/fs4 | Saves the current font configuration as configuration 4 |
/fs5 | Saves the current font configuration as configuration 5 |
/fs6 | Saves the current font configuration as configuration 6 |
/fs7 | Saves the current font configuration as configuration 7 |
/fs8 | Saves the current font configuration as configuration 8 |
/fs9 | Saves the current font configuration as configuration 9 |
/f0 | Resets the font to the spreadsheet default font |
/f1 | Recalls font configuration 1 |
/f2 | Recalls font configuration 2 |
/f3 | Recalls font configuration 3 |
/f4 | Recalls font configuration 4 |
/f5 | Recalls font configuration 5 |
/f6 | Recalls font configuration 6 |
/f7 | Recalls font configuration 7 |
/f8 | Recalls font configuration 8 |
/f9 | Recalls font configuration 9 |
Set the PrintHeader property before you use the PrintSheet method to print the spreadsheet.
This property is set at the sheet level. Set the Sheet property before setting this property if there are multiple sheets.
To customize the text and appearance of a printed footer, use the PrintFooter property.
Spread Designer
Choose the Sheet menu, then the Print Properties menu, select the Print Properties tab, and then type text in the Header Text edit box in the Job Setup group box in the Print Properties dialog box.
Data Type
String
See Also
PrintFooter property
PrintSheet method
DLL Correspondence
SSPrint function