Export (0) Print
Expand All
Expand Minimize

Application.FilePageSetupCalendarText Method (Project)

Formats the text of calendar views for printing.

expression .FilePageSetupCalendarText(Name, Item, Font, Size, Bold, Italic, Underline, Color)

expression A variable that represents an Application object.

Parameters

Name

Required/Optional

Data Type

Description

Name

Optional

String

The name of the calendar to edit.

Item

Optional

Long

The text item to format. Can be one of the PjPageSetupCalendarItem constants.

Font

Optional

String

The name of the font.

Size

Optional

Integer

The size of the font in points

Bold

Optional

Boolean

True if the font is bold; otherwise, False.

Italic

Optional

Boolean

True if the font is italic; otherwise, False.

Underline

Optional

Boolean

True if the font is underlined; otherwise, False.

Color

Optional

Long

The color of the text. Can be one of the PjColor constants.

Return Value

Boolean

Using the FilePageSetupCalendarText method without any arguments displays the Text Styles dialog box.

Note Note

FilePageSetupCalendarText works only for printing calendar views.

To format calendar text where Color can be a hexadecimal RGB value, use the FilePageSetupCalendarTextEx method.

The following example formats monthly titles in red for printing.

Sub File_PageSetupCalendarText() 
 
 'Activate the Calandar view. 
 ViewApply Name:="&Calendar" 
 FilePageSetupCalendarText Item:=pjMonthlyTitles, Color:=pjRed 
 FilePrint 
End Sub

Community Additions

ADD
Show:
© 2014 Microsoft