Returns the number of days in the specified month and year.

Namespace:  DlhSoft.Windows.Data
Assembly:  DlhSoft.ProjectData.GanttChart.LightWPF.Controls (in DlhSoft.ProjectData.GanttChart.LightWPF.Controls.dll)

Syntax

C#
public static int DaysInMonth(
	int year,
	int month
)
Visual Basic (Declaration)
Public Shared Function DaysInMonth ( _
	year As Integer, _
	month As Integer _
) As Integer

Parameters

year
Type: System..::.Int32
The year.
month
Type: System..::.Int32
The month (a number ranging from 1 to 12).

Return Value

The number of days in month for the specified year. For example, if month equals 2 for February, the return value is 28 or 29 depending upon whether year is a leap year.

See Also