c# - 为什么 Visual Studio 2019 UWP XAML 设计器显示空白屏幕?
问题描述
我正在试用 UWP,所以我下载了 Windows BuildCast UWP 测试应用程序,并且正在试用它,但完全无法使用 XAML 设计器!以下是错误(作为图像)
和文本〜
System.NullReferenceException
Object reference not set to an instance of an object.
at Microsoft.VisualStudio.DesignTools.UwpSurfaceDesigner.Views.UwpIsolatedImageHost.UwpVisualWrapper.CreateWindowCore()
at Microsoft.VisualStudio.DesignTools.XamlSurfaceDesigner.Views.DisabledHwndHolder.CreateHandle()
at Microsoft.VisualStudio.DesignTools.UwpSurfaceDesigner.Views.UwpIsolatedImageHost.UwpVisualWrapper..ctor(IntPtr parentHwnd, IDCompositionDevice device, UwpSurfaceProcessDocument document, CancellationToken token)
at Microsoft.VisualStudio.DesignTools.UwpSurfaceDesigner.Views.UwpIsolatedImageHost.UwpHwndHost.CreateSurfaceHwnd(IntPtr parentHwnd)
at Microsoft.VisualStudio.DesignTools.XamlSurfaceDesigner.Views.IsolatedSurfaceImageHost.IsolatedHwndHost.BuildWindowCore(HandleRef hwndParent)
at System.Windows.Interop.HwndHost.BuildWindow(HandleRef hwndParent)
at System.Windows.Interop.HwndHost.BuildOrReparentWindow()
at System.Windows.Interop.HwndHost.OnSourceChanged(Object sender, SourceChangedEventArgs e)
at System.Windows.SourceChangedEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
at System.Windows.UIElement.RaiseEvent(RoutedEventArgs e)
at System.Windows.PresentationSource.UpdateSourceOfElement(DependencyObject doTarget, DependencyObject doAncestor, DependencyObject doOldParent)
at System.Windows.PresentationSource.OnVisualAncestorChanged(DependencyObject uie, AncestorChangedEventArgs e)
at System.Windows.UIElement.OnVisualAncestorChanged(Object sender, AncestorChangedEventArgs e)
at System.Windows.Media.Visual.ProcessAncestorChangedNotificationRecursive(DependencyObject e, AncestorChangedEventArgs args)
at System.Windows.Media.Visual.FireOnVisualParentChanged(DependencyObject oldParent)
at System.Windows.Media.Visual.AddVisualChild(Visual child)
at System.Windows.Controls.Decorator.set_Child(UIElement value)
at Microsoft.VisualStudio.DesignTools.XamlSurfaceDesigner.Views.IsolatedSurfaceImageHost.<CreateSurfaceAsync>d__66.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)
System.AggregateException
One or more errors occurred.
我尝试了几件事-
解决方案
推荐阅读
- javascript - 如何安排每个季度的 api 调用?
- python - 无法从 LXML 获取标签
- python - 如何避免/消除表单字段上的完整性错误
- django - Django.session:如何确定 Django 用户会话的开始?
- laravel - 如何在雄辩的关系中显示具有至少一个属性的属性族?
- javascript - 如何将字符串数组从反应状态映射到选择框
- macos - Tomcat - 未正确关闭 - vjava.net.SocketException:错误的文件描述符 - macbook
- javascript - Javascript遍历类onmouseover
- javascript - 自动更改电子中的键盘输入
- angular - 从打字稿中的数组中过滤