【发布时间】:2022-02-17 03:51:49
【问题描述】:
如果我尝试在 Visual Studio 2017 中打开一个 .xsd 文件或创建一个新文件,它是一个 .net 3.5 项目,并且在我重新安装 Windows 并升级到 Visual Studio 2017 Pro 之前工作正常,我会收到以下错误。
这似乎是 .net 3.5 特定的,因为我打开了另一个 4.0 项目,并且它的 .xsd 在设计器中打开。
为防止在加载设计器之前可能丢失数据, 必须解决以下错误:
值不能为空。范围 名称:实例
Instances of this error (1)
- 在 System.ComponentModel.TypeDescriptor.AddAttributes(对象实例, 属性 [] 属性)在 Microsoft.VisualStudio.Design.VSDesignSurface.CreateDesigner(IComponent 组件,布尔根设计器)在 System.ComponentModel.Design.DesignerHost.AddToContainerPostProcess(IComponent 组件,字符串名称,IContainer containerToAddTo)在 System.ComponentModel.Design.DesignerHost.PerformAdd(IComponent 组件,字符串名称)在 System.ComponentModel.Design.DesignerHost.Add(IComponent 组件, 字符串名称)在 System.ComponentModel.Container.Add(IComponent 组件)在 Microsoft.VSDesigner.DataSource.Designer.DataSourceDesignerLoader.HandleLoad(IDesignerSerializationManager 序列化管理器)在 Microsoft.VSDesigner.DesignerFramework.BaseDesignerLoader.PerformLoad(IDesignerSerializationManager 序列化管理器)在 Microsoft.VSDesigner.DesignerFramework.BaseDesignerLoader.Microsoft.VisualStudio.TextManager.Interop.IVsTextBufferDataEvents.OnLoadCompleted(Int32 fReload)
【问题讨论】:
-
无需发布错误图片。在此处将其作为文本复制/粘贴到您的帖子中。
-
是的。我试图嵌入图像,但它只让我链接。
-
只有当问题不能以任何其他方式呈现时才应该使用图像,并且没有必要在此处包含图像。请参阅this Meta post 了解尽可能避免使用图像的原因列表;它指的是代码图像,但许多项目符号项也适用于非代码内容。
-
我实际上认为它在这里很有用。如果您在熟悉的上下文中显示代码或错误,我完全同意,例如 .net 在浏览器中为您提供的那些。但是我以前从未在 Visual Studio 中看到过这样的错误,所以我试图显示上下文以及内容。
标签: .net visual-studio xsd