Skip to main content
A newer version of this page is available. .

DayOfWeekMonthlyOccurrence Enum

Lists values that specify the occurrence of a day of week.

Namespace: DevExpress.Web.ASPxGantt

Assembly: DevExpress.Web.ASPxGantt.v19.2.dll

Declaration

public enum DayOfWeekMonthlyOccurrence

Members

Name Description
First

A rule is applied every first specified day of the week.

Second

A rule is applied every second specified day of the week.

Third

A rule is applied every third specified day of the week.

Forth

A rule is applied every fourth specified day of the week.

Last

A rule is applied every last specified day of the week.

Related API Members

The following properties accept/return DayOfWeekMonthlyOccurrence values:

Remarks

Values of this enumeration are accepted by the DayOfWeekOccurrence property.

The DayOfWeekMonthlyOccurrence class allows you to specify a day of week’s occurrence in a month or in a year. For example, the second Friday in a month.

Web Forms (declaratively):

<dx:ASPxGantt ID="Gantt" runat="server"...>
    ...
    <WorkTimeRules>
        <dx:MonthlyRule>
            <Recurrence DayOfWeek="Thursday" DayOfWeekOccurrence="Second" CalculateByDayOfWeek="true" />
            <WorkTimeRanges>
                <dx:WorkTimeRange Start="08:00" End="16:00" />
            </WorkTimeRanges>
        </dx:MonthlyRule>
    </WorkTimeRules>
</dx:ASPxGantt>

Web Forms (in code):

...
MonthlyRule monthlyRule1 = new MonthlyRule();
monthlyRule1.WorkTimeRanges.AddRange(new List<WorkTimeRange>
{
    new WorkTimeRange(){ Start=new TimeSpan(08,00,00), End=new TimeSpan(16,00,00)}
});
monthlyRule1.Recurrence.DayOfWeek = DayOfWeek.Thursday;
monthlyRule1.Recurrence.DayOfWeekOccurrence = DayOfWeekMonthlyOccurrence.Second;
monthlyRule1.Recurrence.CalculateByDayOfWeek = true;
...
Gantt.WorkTimeRules.Add(monthlyRule1);

Concept

Work Time Rules

Online Demos

See Also