on 2014 Aug 22 5:33 PM
Today, I uninstalled SA from my development machine & reinstalled it with both the 32-bit & 64-bit database engines turned on.
I go into C:\\Progeram Files\\SQL Anywhere 12\\Assembly\\V4 and run SetupVSPackage /I /v 4
I start VS & build my application. When I run it, I keep getting this error over & over:
Failed to find or load the registered .Net Framework Data Provider.
When I look at my machine.config in C:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319\\Config, I have this line in the DbProviderFactories section:
<add name="SQL Anywhere 12 Data Provider" invariant="iAnywhere.Data.SQLAnywhere" description=".Net Framework Data Provider for SQL Anywhere 12" type="iAnywhere.Data.SQLAnywhere.SAFactory, iAnywhere.Data.SQLAnywhere.v4.0, Version=12.0.1.38954, Culture=neutral, PublicKeyToken=f222fc4333e0d400" />
and this line is in the C:\\Windows\\Microsoft.Net\\Framework64\\v4.0.30319\\Config\\machine.config
<add name="SQL Anywhere 12 Data Provider" invariant="iAnywhere.Data.SQLAnywhere" description=".Net Framework Data Provider for SQL Anywhere 12" type="iAnywhere.Data.SQLAnywhere.SAFactory, iAnywhere.Data.SQLAnywhere.v4.0, Version=12.0.1.38954, Culture=neutral, PublicKeyToken=f222fc4333e0d400" />
Finally, this line is in the App.config for my application:
<add invariant="iAnywhere.Data.SQLAnywhere" name="SQL Anywhere 12 Data Provider" description=".Net Framework Data Provider for SQL Anywhere 12" type="iAnywhere.Data.SQLAnywhere.SAFactory, iAnywhere.Data.SQLAnywhere.v4.0" />
It doesn't matter if I have the 32-bit or the 64-bit server running, I get the same message. This all worked before I uninstalled SA & reinstalled it. What is wrong with my configuration and how do I fix it?
I found the problem.
Another developer modified the references & the location where the SA dlls are in the project, and when he did, the references to the SA DLLs in the projects that use them had Copy Local in the reference properties set to False. I changed Copy Local to True and the code ran fine.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
72 | |
10 | |
10 | |
10 | |
10 | |
8 | |
8 | |
7 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.