Article ID: 813354 - Last Review: May 12, 2007 - Revision: 1.5 FIX: You may notice a memory leak when you use the DateTimePicker control in the .NET Framework 1.0On This PageSYMPTOMSIf you create an application by using the Microsoft .NET
Framework version 1.0, and you use the DateTimePicker control in the application, you may notice a memory leak when you
run the application. CAUSEThis problem occurs because the garbage collector does not
collect the inaccessible memory. The DateTimePicker control is associated with the Microsoft.Win32.UserPreferenceChangedEventHandler delegate. When you dispose of an object of the DateTimePicker control, this delegate is not dereferenced. Therefore, this
delegate prevents the garbage collector from collecting the DateTimePicker control object. RESOLUTIONTo resolve this problem, obtain the latest service pack for
the .NET Framework 1.0. To obtain the latest service pack, visit the following Microsoft Web site: http://www.microsoft.com/downloads/details.aspx?familyid=6978D761-4A92-4106-A9BC-83E78D4ABC5B&displaylang=en
(http://www.microsoft.com/downloads/details.aspx?familyid=6978D761-4A92-4106-A9BC-83E78D4ABC5B&displaylang=en)
STATUSMicrosoft
has confirmed that this is a problem in the Microsoft products that are listed
in the "Applies to" section. This problem was
first corrected in the Microsoft .NET Framework 1.0 Service Pack
3. MORE INFORMATIONSteps to reproduce the behavior
824684
(http://support.microsoft.com/kb/824684/
)
Description of the standard terminology that Is used To describe Microsoft software updates REFERENCESFor more information about the UserPreferenceChangedEventHandler delegate, visit the following Microsoft Developer Network (MSDN)
Web site: http://msdn2.microsoft.com/en-us/library/microsoft.win32.userpreferencechangedeventhandler(vs.71).aspx
(http://msdn2.microsoft.com/en-us/library/microsoft.win32.userpreferencechangedeventhandler(vs.71).aspx)
For more information about the DateTimePicker class, visit the following MSDN Web site:http://msdn2.microsoft.com/en-us/library/system.windows.forms.datetimepicker(vs.71).aspx
(http://msdn2.microsoft.com/en-us/library/system.windows.forms.datetimepicker(vs.71).aspx)
| Article Translations
|
Back to the top
