vs2010下载入设计器异常问题(费了3天的时间终于解决)
2011-05-16 12:42
507 查看
在vs2010下新建silverlight application刚刚建好就出现设计器载入异常的问题。代码都是有vs2010自动产生的,所以代码应该没问题。求解释,这个困然了我很久了。
以下是vs2010给出的提示:System.NullReferenceException
未将对象引用设置到对象的实例。
在 Microsoft.Windows.Design.Platform.SilverlightMetadataContext.SilverlightXamlExtensionImplementations.<GetXmlNamespaceCompatibilityMappings>d__8.MoveNext()
在 MS.Internal.Design.Metadata.ReflectionProjectNode.BuildSubsumption()
在 MS.Internal.Design.Metadata.ReflectionProjectNode.SubsumingNamespace(Identifier identifier)
在 MS.Internal.Design.Markup.XmlElement.BuildScope(PrefixScope parentScope, IParseContext context)
在 MS.Internal.Design.Markup.XmlElement.ConvertToXaml(XamlElement parent, PrefixScope parentScope, IParseContext context, IMarkupSourceProvider provider)
在 MS.Internal.Design.DocumentModel.DocumentTrees.Markup.XamlSourceDocument.FullParse(Boolean convertToXamlWithErrors)
在 MS.Internal.Design.DocumentModel.DocumentTrees.Markup.XamlSourceDocument.get_RootItem()
在 Microsoft.Windows.Design.DocumentModel.Trees.ModifiableDocumentTree.get_ModifiableRootItem()
在 Microsoft.Windows.Design.DocumentModel.MarkupDocumentManagerBase.get_LoadState()
在 MS.Internal.Host.PersistenceSubsystem.Load()
在 MS.Internal.Host.Designer.Load()
在 MS.Internal.Designer.VSDesigner.Load()
在 MS.Internal.Designer.VSIsolatedDesigner.VSIsolatedView.Load()
在 MS.Internal.Designer.VSIsolatedDesigner.VSIsolatedDesignerFactory.Load(IsolatedView view)
在 MS.Internal.Host.Isolation.IsolatedDesigner.BootstrapProxy.LoadDesigner(IsolatedDesignerFactory factory, IsolatedView view)
在 MS.Internal.Host.Isolation.IsolatedDesigner.BootstrapProxy.LoadDesigner(IsolatedDesignerFactory factory, IsolatedView view)
在 MS.Internal.Host.Isolation.IsolatedDesigner.Load()
在 MS.Internal.Designer.DesignerPane.LoadDesignerView()
一下是vs2010产生的代码:<UserControl x:Class="FirstSliverlight.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
d:DesignHeight="300" d:DesignWidth="400">
<Grid x:Name="LayoutRoot" Background="White">
</Grid>
</UserControl>
以及错误列表中的提示:错误 1 未将对象引用设置到对象的实例。 D:/My workspace/SilverLight/FirstSliverlight/FirstSliverlight/MainPage.xaml 1 1 FirstSliverlight
错误 2 在“D:/My workspace/SilverLight/FirstSliverlight/FirstSliverlight/MainPage.xaml”上引发了 System.NullReferenceException: 未将对象引用设置到对象的实例。 D:/My workspace/SilverLight/FirstSliverlight/FirstSliverlight/MainPage.xaml 1 1 FirstSliverlight
解决方案:
先说我的解决流程:
第一种解决方案(不行):
卸载vs2010,然后重装。(当初以为2010出了问题)
第二种方案(也不行):打开silverlight tookit命令,按以下操作:1.打开 visual studio 命令提示 输入一下命令
2.devenv /resetskippkgs 这条命令会启动visual stuio 关闭visual studio然后输入下面的命令
3.devenv /setup
第三种方案(OK):先把所有与siverlight有关的silverlight,silverlightsdk,silverlight_too ,silverlight toolkit,全部卸掉,然后重装,然后启动2010,打开原来的silverlight的项目OK,新疆项目也OK
总结:通过以上解决方法,可以看出silverlight的开发环境要求比较严格,并且其开发环境不是集成在一个安装包,而是分散的,所以安装时必须注意版本和顺序,否则就可能造成意想不到的问题。所谓版本要求个人和网上理解为要么全部为中文版,全部为英文版,并且版本号尽量一致,以前我安装的时候碰到了一个版本不一致问题就是,我安装了vs2010英文旗舰版,然后安装中文版silverlight_tools,就出现问题.
所以我总结了一下安装顺序应该为1、vs2010。2、silverlight4。3、silverlight4_tool.(其中包含)4、silverlight toolkit
最后祝各位碰到此问题的朋友能摆脱此问题的困扰!!!!!!!!!!
以下是vs2010给出的提示:System.NullReferenceException
未将对象引用设置到对象的实例。
在 Microsoft.Windows.Design.Platform.SilverlightMetadataContext.SilverlightXamlExtensionImplementations.<GetXmlNamespaceCompatibilityMappings>d__8.MoveNext()
在 MS.Internal.Design.Metadata.ReflectionProjectNode.BuildSubsumption()
在 MS.Internal.Design.Metadata.ReflectionProjectNode.SubsumingNamespace(Identifier identifier)
在 MS.Internal.Design.Markup.XmlElement.BuildScope(PrefixScope parentScope, IParseContext context)
在 MS.Internal.Design.Markup.XmlElement.ConvertToXaml(XamlElement parent, PrefixScope parentScope, IParseContext context, IMarkupSourceProvider provider)
在 MS.Internal.Design.DocumentModel.DocumentTrees.Markup.XamlSourceDocument.FullParse(Boolean convertToXamlWithErrors)
在 MS.Internal.Design.DocumentModel.DocumentTrees.Markup.XamlSourceDocument.get_RootItem()
在 Microsoft.Windows.Design.DocumentModel.Trees.ModifiableDocumentTree.get_ModifiableRootItem()
在 Microsoft.Windows.Design.DocumentModel.MarkupDocumentManagerBase.get_LoadState()
在 MS.Internal.Host.PersistenceSubsystem.Load()
在 MS.Internal.Host.Designer.Load()
在 MS.Internal.Designer.VSDesigner.Load()
在 MS.Internal.Designer.VSIsolatedDesigner.VSIsolatedView.Load()
在 MS.Internal.Designer.VSIsolatedDesigner.VSIsolatedDesignerFactory.Load(IsolatedView view)
在 MS.Internal.Host.Isolation.IsolatedDesigner.BootstrapProxy.LoadDesigner(IsolatedDesignerFactory factory, IsolatedView view)
在 MS.Internal.Host.Isolation.IsolatedDesigner.BootstrapProxy.LoadDesigner(IsolatedDesignerFactory factory, IsolatedView view)
在 MS.Internal.Host.Isolation.IsolatedDesigner.Load()
在 MS.Internal.Designer.DesignerPane.LoadDesignerView()
一下是vs2010产生的代码:<UserControl x:Class="FirstSliverlight.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
d:DesignHeight="300" d:DesignWidth="400">
<Grid x:Name="LayoutRoot" Background="White">
</Grid>
</UserControl>
以及错误列表中的提示:错误 1 未将对象引用设置到对象的实例。 D:/My workspace/SilverLight/FirstSliverlight/FirstSliverlight/MainPage.xaml 1 1 FirstSliverlight
错误 2 在“D:/My workspace/SilverLight/FirstSliverlight/FirstSliverlight/MainPage.xaml”上引发了 System.NullReferenceException: 未将对象引用设置到对象的实例。 D:/My workspace/SilverLight/FirstSliverlight/FirstSliverlight/MainPage.xaml 1 1 FirstSliverlight
解决方案:
先说我的解决流程:
第一种解决方案(不行):
卸载vs2010,然后重装。(当初以为2010出了问题)
第二种方案(也不行):打开silverlight tookit命令,按以下操作:1.打开 visual studio 命令提示 输入一下命令
2.devenv /resetskippkgs 这条命令会启动visual stuio 关闭visual studio然后输入下面的命令
3.devenv /setup
第三种方案(OK):先把所有与siverlight有关的silverlight,silverlightsdk,silverlight_too ,silverlight toolkit,全部卸掉,然后重装,然后启动2010,打开原来的silverlight的项目OK,新疆项目也OK
总结:通过以上解决方法,可以看出silverlight的开发环境要求比较严格,并且其开发环境不是集成在一个安装包,而是分散的,所以安装时必须注意版本和顺序,否则就可能造成意想不到的问题。所谓版本要求个人和网上理解为要么全部为中文版,全部为英文版,并且版本号尽量一致,以前我安装的时候碰到了一个版本不一致问题就是,我安装了vs2010英文旗舰版,然后安装中文版silverlight_tools,就出现问题.
所以我总结了一下安装顺序应该为1、vs2010。2、silverlight4。3、silverlight4_tool.(其中包含)4、silverlight toolkit
最后祝各位碰到此问题的朋友能摆脱此问题的困扰!!!!!!!!!!
相关文章推荐
- vs2010下载入silverlight设计器异常问题(转载)
- VS2010 SP1下载(解决wp7设计页面加载出错的问题)
- 困扰我3天的问题终于解决了!
- 时间单位m和ms弄错导致系统概率异常, 耗费1天多才解决问题!
- 解决springmvc中文件下载功能中使用javax.servlet.ServletOutputStream out = response.getOutputStream();后运行出异常但结果正确的问题
- 关于vs2010(C++ 工程)的异常问题(this is not a valid c/c++ file .CPP)的解决(C++ 初学者)
- 不能下载的问题终于解决啦
- [2013.7.5新鲜出炉] Ubuntu12.04下载Android4.0.1源码全过程----------------折腾两天,终于下好,附若干问题解决
- 关于 php 用webservice传输数据的问题(nosoap与.NET对接)此处一直困扰三天时间,终于解决
- 关于“超时时间已到”的问题,终于解决了
- Xcode7---项目模拟器运行不了,一个月时间了,终于解决问题啦
- [2013.7.5新鲜出炉] Ubuntu12.04下载Android4.0.1源码全过程----------------折腾两天,终于下好,附若干问题解决
- 终于解决了中文文件名文件下载的问题
- 运行VS2010后CPU占用率高,鼠标指针旁的沙漏一闪一闪,终于解决这个问题了!
- 【转】彻底解决Asp.net文件下载(Response.WriteFile)时文件名的中文乱码和空格异常问题
- VS2010不能载入设计器问题的解决
- 这些天很忙,写一个类似防火墙的东西在WINSOCK2 SPI上做DLL,终于把问题解决了,现提供完整C++项目下载
- WebApp由于需要从Spring官网下载schema文件导致启动时长时间卡住问题的分析和解决
- 终于解决用JFlash ARM直接下载的问题了
- 关于“超时时间已到”的问题,终于解决了