Skip to content

Latest commit

 

History

History
123 lines (77 loc) · 4.31 KB

taskschedulerschema-schedulebymonth-calendartriggertype-element.md

File metadata and controls

123 lines (77 loc) · 4.31 KB
title description ms.assetid keywords topic_type api_name api_type ms.topic ms.date api_location
ScheduleByMonth (calendarTriggerType) Element
Specifies a monthly schedule.
3a23f4d0-bdaf-4f2a-81c6-8652a0849fc8
ScheduleByMonth element Task Scheduler
apiref
ScheduleByMonth
Schema
reference
05/31/2018

ScheduleByMonth (calendarTriggerType) Element

Specifies a monthly schedule. For example, the task starts at 8:00 AM on specific days of the month on specific months.

<xs:element name="ScheduleByMonth"
    type="monthlyScheduleType"
 />

The ScheduleByMonth element is defined by the calendarTriggerType complex type.

Parent element

Element Derived from Description
CalendarTrigger calendarTriggerType Specifies a daily, weekly, monthly, or a monthly day-of-the-week (DOW) trigger.

Child elements

Element Type Description
DaysOfMonth (monthlyScheduleType) daysOfMonthType Specifies the days of the month during which the task runs.
Months (monthlyScheduleType) monthsType Specifies the months of the year during which the task runs.

Remarks

The time of day that the task is started is set by the StartBoundary element.

For script development, a monthly trigger is specified using the MonthlyTrigger object.

For C++ development, a monthly trigger is specified using the IMonthlyTrigger interface.

The child elements listed below are defined by the monthlyScheduleType complex element types.

Examples

The following XML defines a monthly calendar trigger that starts a task ( at 8:00 AM) on the 1st and 15th day of every month of the year.

<CalendarTrigger>
    <StartBoundary>2005-01-01T08:00:00</StartBoundary>
    <EndBounadry>2007-01-01T00:00:00</EndBoundary>
    <ScheduleByMonth>
        <DaysOfMonth>
            <Day>1</Day>
            <Day>15</Day>
        </DaysOfMonth>
        <Months>
            <January/>
            <February/>
            <March/>
            <April/>
            <May/>
            <June/>
            <July/>
            <August/>
            <September/>
            <October/>
            <November/>
            <December/>
        </Months>
    </ScheduleByMonth>
</CalendarTrigger>

Requirements

Requirement Value
Minimum supported client
Windows Vista [desktop apps only]
Minimum supported server
Windows Server 2008 [desktop apps only]

See also

Task Scheduler Schema Elements

Task Scheduler