我安装了VS2013Update 3,现在打开解决方案时会出现错误:
'Microsoft.VisualStudio.Web.Publish.WebPublishPackage,MircosoftVisualStudio.Web.Publish的包没有正确加载。
和
“ScaffoldungVSPackage”包没有正确加载。
其结果是,我无法打开发布对话框,并且在创建新的Webproject时没有模板。
在activitylog中有以下错误:
<entry>
<record>447</record>
<time>2014/08/05 14:27:31.859</time>
<type>Error</type>
<source>VisualStudio</source>
<description>End package load [Microsoft.VisualStudio.Web.Publish.WebPublishPackage, Microsoft.VisualStudio.Web.Publish]</description>
<guid>{1AD387FC-B1E8-4023-91FE-F22260B661DB}</guid>
<hr>80131522</hr>
<errorinfo>Could not load type 'Microsoft.VisualStudio.Web.Internal.Contracts.Publish.IVsWebJobPublishService' from assembly 'Microsoft.VisualStudio.Web.Internal.Contracts, Version=2.3.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.</errorinfo>
</entry>
<entry>
<record>450</record>
<time>2014/08/05 14:31:20.199</time>
<type>Error</type>
<source>VisualStudio</source>
<description>SetSite failed for package [ScaffoldingVsPackage]</description>
<guid>{FAA496BF-FB16-4671-B3D5-E4B388A18478}</guid>
<hr>80131500</hr>
<errorinfo>Cannot cast the underlying exported value of type 'Microsoft.AspNet.Scaffolding.Templating.ScaffoldingAssemblyDirectiveProcessor (ContractName="Microsoft.AspNet.Scaffolding.IServiceRegistrar")' to type 'Microsoft.AspNet.Scaffolding.IServiceRegistrar'.</errorinfo>
</entry>
<entry>
<record>451</record>
<time>2014/08/05 14:31:20.199</time>
<type>Error</type>
<source>VisualStudio</source>
<description>End package load [ScaffoldingVsPackage]</description>
<guid>{FAA496BF-FB16-4671-B3D5-E4B388A18478}</guid>
<hr>80131500</hr>
<errorinfo>Cannot cast the underlying exported value of type 'Microsoft.AspNet.Scaffolding.Templating.ScaffoldingAssemblyDirectiveProcessor (ContractName="Microsoft.AspNet.Scaffolding.IServiceRegistrar")' to type 'Microsoft.AspNet.Scaffolding.IServiceRegistrar'.</errorinfo>
</entry>有没有人知道如何解决这个问题?我已经试过了
谢谢!
发布于 2014-08-07 15:47:26
来自ASP.NET论坛的下列解决方案对我有效:
解决方案是使用Developer命令提示符作为管理员重置用于契约和发布的程序集,如果您使用了默认安装设置,那么这可能是路径 gacutil -i "C:\Program (X86)\MicrosoftVisualStudio12.0\Common7\IDE\-i\Microsoft\Web gacutil -i "C:\Program (X86)\MicrosoftVisualStudio12.0\Common7\IDE\-i\Microsoft\Web
下面是链接:http://forums.asp.net/p/2000916/5751509.aspx?p=True&t=635430085558824221&pagenum=1
发布于 2016-01-14 16:25:22
我通过下载程序集并重新启动VS2013更新5解决了这个问题。
https://www.microsoft.com/en-us/download/details.aspx?id=43709
https://stackoverflow.com/questions/25154024
复制相似问题