问题描述
我正在尝试这里,但仍然失败。
我的Windows Server 2008 R2上安装了Visual Studio Developer Preview。如你所知,现在的VS扩展与VS 11 Dev Preview不兼容,但我发现了一个解决方法:
我安装了在VS 11,但是当我尝试运行代码生成时,我收到以下错误:
我从添加参考页面检查,没有像上面的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:
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的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!