AccessViolationException: 尝试读取或写入受保护的内存。这通常指示其他内存已损坏。 StackTrace: 在 System.Windows.DependencyObject.GetValue(DependencyProperty dp) 在 System.Windows.FrameworkElement.get_MinWidth() 在 System.Windows.FrameworkElement.MinMax..ctor(FrameworkElement e) 在 System.Windows.FrameworkElement.MeasureCore(Size availableSize) 在 System.Windows.UIElement.Measure(Size availableSize) 在 System.Windows.ContextLayoutManager.UpdateLayout() 在 System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg) 在 System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks() 在 System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget) 在 System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget) 在 System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs) 在 System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)