The WinCalendar control does not offer a property or method that allows you to specify the number of calendar months to display vertically and horizontally. In order to specify the number of calendar months to display, the width and height of the WinCalendar control must be adjusted accordingly and the EnableMultipleMonths property set to true.
For example, to display 2 x 2 months, the width and height of the WinCalendar control must be multiplied by 2. To display 3 x 2 months, the width must be multiplied by 3 and the height by 2.
VB.NET |
Copy Code |
---|---|
Dim calendar As New Xceed.Editors.WinCalendar( True, True ) calendar.EnableMultipleMonths = True ' Adjust the size so 4 months will fit into the calendar calendar.Height = calendar.Height * 2 calendar.Width = calendar.Width * 2 calendar.Location = New Point( 10, 10 ) Me.Controls.Add( calendar ) |