Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Composit Control - Is Dispose Needed

Status
Not open for further replies.

Auguy

Programmer
May 1, 2004
1,206
US
I have a composite control (with a button, a label, a checked list box, and two text boxes) that creates among other things a data view and 2 string builders. Do I need to dispose of these manually as in the following code? Or is this not necessary as they should be cleaned up when the form is closed?
Code:
 Private Sub SearchPanelCheckList1_Disposed(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Disposed
    cklDataSourceView = Nothing
    stbDesc.Length = 0
    stbDesc = Nothing
    stbPK.Length = 0
    stbPK = Nothing
End Sub

Auguy
Sylvania/Toledo Ohio
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top