property Calendar.SingleSel as Boolean
Retrieves or sets a value that indicates whether the control supports single or multiple selection.

TypeDescription
Boolean A boolean expression that indicates whether the control supports single or multiple selection.

Use the SingleSel property to specify whether the control supports single or multiple selection. By default, the SingleSel property is True. If the user selects a new date, the SelectionChanged event is fired. Use the SelDate or SelectDate property to get the selected date(s). Use the FocusDate property to specify the date that has the focus. Use the SelCount property to retrieve the number of selected dates. Use the UnSelDate property unselects a date.

The following VB sample prints the selected date(s):

With Calendar1
    Dim i As Long
    For i = 0 To .SelCount - 1
        Debug.Print FormatDateTime(.SelectDate(i), vbLongDate)
    Next
End With

The following C++ sample prints the selected date(s):

for ( long i = 0 ; i < m_calendar.GetSelCount() ; i++ )
{
	COleDateTime date = m_calendar.GetSelDate();
	OutputDebugString( date.Format() );
}

The following VB.NET sample prints the selected date(s):

With AxCalendar1
    Dim i As Integer
    For i = 0 To .SelCount - 1
        System.Diagnostics.Debug.WriteLine(.get_SelectDate(i).ToString())
    Next
End With

The following C# sample prints the selected date(s):

for (int i = 0; i < axCalendar1.SelCount; i++)
	System.Diagnostics.Debug.WriteLine(axCalendar1.get_SelectDate(0).ToString());

The following VFP sample prints the selected date(s):

with thisform.Calendar1
	local i, d
	for i = 0 to .SelCount -1
		d = .SelectDate(i)
	next
endwith