Please place [ MonthView1 , CommandButton1 , CommandButton2 , ListBox1 ] in UserForm.
--- UserForm module ---
Kod:
Private WithEvents BoldMonthView As clsBoldMonthView
Private Sub UserForm_Initialize()
Set BoldMonthView = New clsBoldMonthView
Set BoldMonthView.MonthView = MonthView1
End Sub
Private Sub UserForm_Terminate()
Set BoldMonthView = Nothing
End Sub
Private Sub BoldMonthView_DateClick(ByVal DateClicked As Date, ByVal BoldState As Boolean)
' MsgBox DateClicked & " ( " & BoldState & " )"
End Sub
Private Sub CommandButton1_Click()
Dim Temp As Collection
Dim i As Integer
ListBox1.Clear
Set Temp = BoldMonthView.BoldStaes
If (Temp.Count > 0) Then
For i = 1 To Temp.Count
ListBox1.AddItem Format(Temp.Item(i), "yyyy/mm/dd")
Next i
End If
End Sub
Private Sub CommandButton2_Click()
BoldMonthView.Reset
ListBox1.Clear
End Sub