Share via


CalendarView.CalendarViewMode プロパティ (Outlook)

CalendarView オブジェクトの現在のビュー モードを決定する OlCalendarViewMode を設定します。 値の取得と設定が可能です。

構文

CalendarViewMode

CalendarView オブジェクトを表す変数。

次の Visual Basic for Applications (VBA) の例では、アイテムと時刻の値と、ビュー内のタスクのヘッダーを表示するのには 16 ポイント、Verdana フォントを表示するのには 8 ポイント、Verdana フォントを使用して 1 日を表示するのには、現在の CalendarView オブジェクトを構成します。

Sub ConfigureDayViewFonts() 
 
 Dim objView As CalendarView 
 
 
 
 ' Check if the current view is a calendar view. 
 
 If Application.ActiveExplorer.CurrentView.ViewType = _ 
 
 olCalendarView Then 
 
 
 
 ' Obtain a CalendarView object reference for the 
 
 ' current calendar view. 
 
 Set objView = _ 
 
 Application.ActiveExplorer.CurrentView 
 
 
 
 With objView 
 
 ' Set the calendar view to show a 
 
 ' single day. 
 
 .CalendarViewMode = olCalendarViewDay 
 
 
 
 ' Set the DayWeekFont to 8-point Verdana. 
 
 .DayWeekFont.Name = "Verdana" 
 
 .DayWeekFont.Size = 8 
 
 
 
 ' Set the DayWeekTimeFont to 16-point Verdana. 
 
 .DayWeekTimeFont.Name = "Verdana" 
 
 .DayWeekTimeFont.Size = 16 
 
 
 
 ' Save the calendar view. 
 
 .Save 
 
 End With 
 
 End If 
 
End Sub

関連項目

CalendarView オブジェクト

サポートとフィードバック

Office VBA またはこの説明書に関するご質問やフィードバックがありますか? サポートの受け方およびフィードバックをお寄せいただく方法のガイダンスについては、Office VBA のサポートおよびフィードバックを参照してください。