Microsoft.Data.Entity.Design,Version = 10.0.0.0适用于Visual Studio Developer Preview 11 [英] Microsoft.Data.Entity.Design, Version=10.0.0.0 is for Visual Studio Developer Preview 11

查看:157
本文介绍了Microsoft.Data.Entity.Design,Version = 10.0.0.0适用于Visual Studio Developer Preview 11的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试这里,但仍然失败。



我的Windows Server 2008 R2上安装了Visual Studio Developer Preview。如你所知,现在的VS扩展与VS 11 Dev Preview不兼容,但我发现了一个解决方法:



Visual Studio Extensions和Visual Studio 11 Dev。预览



我安装了 ADO.NET C#DbContext Generator 在VS 11,但是当我尝试运行代码生成时,我收到以下错误:


错误:此模板尝试加载组件汇编
'Microsoft.Data.Entity.Design,Version = 10.0.0.0,Culture = neutral,
PublicKeyToken = b03f5f7f11d50a3a'。有关此问题的更多信息
以及如何启用此模板,请参阅
上的文档自定义项目模板。


我从添加参考页面检查,没有像上面的dll。



任何机会,我可以使用VS 11 Dev。

解决方案

好的,我解决了问题,但我不确定是否合法。
$ b

当您解压缩扩展名时,导航到 T / code / 文件夹里面,有一个名为 DbContextCS.zip的zip文件即可。解压缩,并且您将看到文件称为 ADONETArtifactGenerator_DbContextCSharp.vstemplate



使用文本编辑器打开此文件,并更改此代码:

   WizardExtension> 
< Assembly> Microsoft.Data.Entity.Design,Version = 10.0.0.0,Culture = neutral,PublicKeyToken = b03f5f7f11d50a3a< / Assembly>
< FullClassName> Microsoft.Data.Entity.Design.VisualStudio.ModelWizard.AddArtifactGeneratorWizard< / FullClassName>
< / WizardExtension>

对于这一个:

 < WizardExtension> 
< Assembly> Microsoft.Data.Entity.Design,Version = 11.0.0.0,Culture = neutral,PublicKeyToken = b03f5f7f11d50a3a< / Assembly>
< FullClassName> Microsoft.Data.Entity.Design.VisualStudio.ModelWizard.AddArtifactGeneratorWizard< / FullClassName>
< / WizardExtension>

将所有内容都放在一起并安装扩展名,当您运行代码gen时,您将没有问题。


I am trying something here but keep failing.

I have Visual Studio Developer Preview installed on a Windows Server 2008 R2. As you know, for now VS extensions are not compatible with VS 11 Dev Preview but I found a workaround:

Visual Studio Extensions and Visual Studio 11 Dev. Preview

I installed ADO.NET C# DbContext Generator on VS 11 but when I try to run the code generation, I am getting the following error:

Error: this template attempted to load component assembly 'Microsoft.Data.Entity.Design, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. For more information on this problem and how to enable this template, please see documentation on Customizing Project Templates.

I checked from the add reference page, there is no dll like above.

Any chance I can get this work with VS 11 Dev. Preview?

解决方案

Ok, I solved the problem but I am not sure it is legitimate or not.

when you unzip the extension, navigate to T/code/ folder inside that, there is a zip file called DbContextCS.zip. Unzip that as well, and you will see file called ADONETArtifactGenerator_DbContextCSharp.vstemplate

Open this up with text editor and change this code:

  <WizardExtension>
    <Assembly>Microsoft.Data.Entity.Design, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</Assembly>
    <FullClassName>Microsoft.Data.Entity.Design.VisualStudio.ModelWizard.AddArtifactGeneratorWizard</FullClassName>
  </WizardExtension>

To this one:

  <WizardExtension>
    <Assembly>Microsoft.Data.Entity.Design, Version=11.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</Assembly>
    <FullClassName>Microsoft.Data.Entity.Design.VisualStudio.ModelWizard.AddArtifactGeneratorWizard</FullClassName>
  </WizardExtension>

Pack everything back together and install the extension, when you run the code gen., you will have no problem.

这篇关于Microsoft.Data.Entity.Design,Version = 10.0.0.0适用于Visual Studio Developer Preview 11的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆