|Long||A long expression that indicates the non-working days in a week.|
You can select the non-working week days in the following table ( In Internet Explorer, you have to allow running the script on this page ).
Click the Bit row for non-working week days and the value for property is:
The last significant byte in the NonworkingDays expression has the following meaning:
where X could be 1 ( nonworking day ) or 0 ( working day ), Sa means Saturday, Fr means Friday, and so on. For instance, the 65 value means Saturday and Sunday are non-working days. Use the AddNonworkingDate method to add custom dates as being nonworking dates.
Use the ShowNonworkingDates property to show or hide the nonworking dates in the control's chart area. Use the NonworkingDaysPattern property to specify the pattern being used to fill non-working days. The NonworkingDaysColor property specifies the color being used to fill the non-working days. For instance, if the NonworkingDaysPattern is exPatternEmpty the non-working days are not highlighted. Use the MarkTodayColor property to specify the color to mark the today date. Use the DrawGridLines property to specify whether the control draws the grid lines in the chart's area. Use the GridLineColor property to specify the color for grid lines. Use the DrawGridLines property to specify whether the control draws the grid lines in the items area. Use the DrawGridLines property to draw grid lines for a specified level. Use the Add("A:B") to add a bar that displays the bar A in the working area, and B in non-working areas.
The following VB sample retrieves the value to indicate Sunday and Monday as being non-working days:
With Gantt1.Chart .NonworkingDays = 2 ^ (EXGANTTLibCtl.exSunday) Or 2 ^ (EXGANTTLibCtl.exMonday) End With
The following C++ sample retrieves the value to indicate Sunday and Monday as being non-working days:
m_gantt.GetChart().SetNonworkingDays( 1 << ( EXGANTTLib::exSunday ) | 1 << ( EXGANTTLib::exMonday ) );
where the #import <exgantt.dll> must be called to insert definitions for types in the control's type library.
The following VB.NET sample retrieves the value to indicate Sunday and Monday as being non-working days:
With AxGantt1.Chart .NonworkingDays = 2 ^ (EXGANTTLib.WeekDayEnum.exSunday) Or 2 ^ (EXGANTTLib.WeekDayEnum.exMonday) End With
The following C# sample retrieves the value to indicate Sunday and Monday as being non-working days:
axGantt1.Chart.NonworkingDays = 1 << (Convert.ToInt32(EXGANTTLib.WeekDayEnum.exSunday) ) | 1 << (Convert.ToInt32(EXGANTTLib.WeekDayEnum.exMonday));
The following VFP sample retrieves the value to indicate Sunday and Monday as being non-working days:
with thisform.Gantt1.Chart .NonworkingDays = 2 ^ 0 + 2 ^ 1 endwith