Microsoft KB Archive/836675

= Object properties in the PropertyDescriptorCollection class do not update as you expect =

Article ID: 836675

Article Last Modified on 2/9/2006

-

APPLIES TO


 * Microsoft Visual Basic .NET 2003 Standard Edition
 * Microsoft Visual Basic .NET 2002 Standard Edition
 * Microsoft Visual C# .NET 2003 Standard Edition
 * Microsoft Visual C# .NET 2002 Standard Edition

-





SYMPTOMS
When you call the PropertyDescriptorCollection.Clear method, and you add PropertyDescriptor objects to your Microsoft Visual Basic .NET project, you may find that the properties of the objects in the PropertyDescriptorCollection class are not updated as you expect when you run your project. This problem occurs when the objects that you added have the same name as objects in the PropertyDescriptorCollection class before you called the PropertyDescriptorCollection.Clear method.



CAUSE
The problem occurs because the PropertyDescriptorCollection.Clear method does not remove cached objects from the collection.



WORKAROUND
To work around this problem, destroy the original PropertyDescriptorCollection class, and then create a new collection.



STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the &quot;Applies to&quot; section.

Keywords: kbprb kbvs2005swept kbvs2005doesnotapply KB836675

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.