3

私は EF6 をインストールしましたが、MySQL がまだ Connector/Net でサポートしていないことに気付きました。当然、ロールバックしたところ、タイトルに記載されているエラーが発生しました。

私のapp.configは次のようになります

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <configSections>
    <section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
    <!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
  </configSections>
  <entityFramework>
    <defaultConnectionFactory type="System.Data.Entity.Infrastructure.LocalDbConnectionFactory, EntityFramework">
      <parameters>
        <parameter value="v11.0" />
      </parameters>
    </defaultConnectionFactory>
  </entityFramework>
</configuration>

そして私の参照は次のようになります:

名前: EntityFramework.dll
作成者: Microsoft Corporation
バージョン: 5.0.20627.0

さらに、次のアセンブリを参照しました。

名前: System.Data
バージョン: 4.0.0.0
ファイル バージョン: 4.030319.17929

名前: System.Data.Entity
バージョン: 4.0.0.0
ファイル バージョン: 4.030319.17929

私が得る例外の正確なテキストは次のとおりです。

entityFramework の構成セクション ハンドラの作成中にエラーが発生しました: ファイルまたはアセンブリ 'EntityFramework, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' またはその依存関係の 1 つを読み込めませんでした。見つかったアセンブリのマニフェスト定義がアセンブリ参照と一致しません。(HRESULT からの例外: 0x80131040)

どうすればこれを修正できますか??

4

1 に答える 1