Mark Kim's answer in this thread: http://social.msdn.microsoft.com/Forums/en/netfxbcl/thread/172f4f77-601e-4b4f-8d98-582f8f62a98e
Hi Matt
In .NET 2.0, this error is almost always caused by multiple threads modifying the Hashtable at the same time. The fix is ββto insert locks before modifying the Hashtable, since the Hashtable is not a multi-user thread. Another possible solution is to work with a synchronized shell through Hashtable.Synchronized, however we recommend using it for finer control.
So fix if this is your code that modifies a hashtable. Based on the information you provided, I think this is not the case. You mentioned that you are experiencing this error with the ASP 2.0 website, so this could be caused by a Hashtable downstream subscriber. For example, if the call stack looks something like this: note that this is a bug fixed for the latest version.
Thanks Kim
Stack trace: in System.Collections.Hashtable.Insert (object key, object nvalue value, logical addition) in System.Collections.Hashtable.set_Item (object key, object value) in System.ComponentModel.TypeDescriptor.CheckDefaultProvider (type type) in System.ComponentModel.TypeDescriptor.NodeFor (Type Type, Boolean createDelegator) in System.ComponentModel.TypeDescriptor.GetDescriptor (Type Type, String typeName) in System.ComponentModel.TypeDescriptor.GetAttributes (Type.Type.Table.Tablepea.Upributes). IsTypeThemeable (Type Type) in System.Web.UI.Control.ApplySkin (page page) in System.Web.UI.Control.InitRecursive (Control namingContainer) in System.Web.UI.Control.InitRecursive (Control namingContainer) in System. Web.UI.Control.InitRecursive (Control namingContainer) in System.Web.UI.Control.InitRecursive (Control namingCo ntainer) in System.Web.UI.Control.InitRecursive (Control namingContainer) in System.Web.UI.Page.ProcessRequestMain (Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
Jason source share