0

由于未知原因,.NET 框架生成了一个内部异常,这使得任何调试过程都无法进行。即使我在 Visual Studio 下以调试模式运行程序,崩溃也是残酷的,没有任何可能看到调用堆栈。完整跟踪:

Exception: System.InvalidOperationException: Collection was modified; enumeration operation may not execute.
   at System.Collections.Hashtable.HashtableEnumerator.MoveNext()
   at MS.Internal.WeakEventTable.Purge(Boolean purgeAll)
   at MS.Internal.CleanupHelper.DoCleanup(Boolean forceCleanup)
   at MS.Internal.Data.DataBindEngine.DoCleanup()
   at MS.Internal.CleanupHelper.DoCleanup(Boolean forceCleanup)
   at MS.Internal.CleanupHelper.OnCleanupTick(Object sender, EventArgs e)
   at System.Windows.Threading.DispatcherTimer.FireTick(Object unused)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

在这种情况下如何进行?

4

0 回答 0