Click here to Skip to main content
15,881,882 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have installed VS2010 on a secondary machine with the latest (I think 6.4.4.4) MySQL. My code was developed under VS2008 with MySQL 6.3.6.3

16 of 20 assemblies migrated successfully, 1 with a little coaxing, and three others that reference a common shared function insist on having a problem due to a GAC reference to MySQL 6.3.6.3.

How do I weed this out?

Note MySQL 6.3.6.3 never existed on this machine, and I have re created the offending assemblies from nothing on the VS2010 box (pasting in the .h and .cpp contents), but it can still see 6.3.6.3. Colour me exasperated!

Further to Mehedi's suggested anwser below
I checked th GAC, and fixed the paths. Did a rebuild all and no joy. A text search finds no reference to 6.3.6 anywhere, but it is still showing up in the console compile:
CSS
1>------ Build started: Project: VT_Console, Configuration: Debug Win32 ------
1>Build started 24/02/2012 05:44:25.
1>ResolveAssemblyReferences:
1>  Consider app.config remapping of assembly "MySql.Data, Culture=neutral, PublicKeyToken=c5687fc88969c44d" from Version "6.3.6.0" [] to Version "6.4.4.0" [C:\Program Files (x86)\MySQL\Connector NET 6.4.4\Assemblies\v4.0\MySql.Data.dll] to solve conflict and get rid of warning.
1>C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.Targets(1490,5): warning MSB3247: Found conflicts between different versions of the same dependent assembly.
1>InitializeBuildStatus:
1>  Creating "Debug\VT_Console.unsuccessfulbuild" because "AlwaysCreate" was specified.
1>GenerateTargetFrameworkMonikerAttribute:
1>Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input files.
1>ClCompile:
1>  All outputs are up-to-date.
1>  All outputs are up-to-date.
1>  All outputs are up-to-date.
1>CoreResGen:
1>  Processing resource file "Form1.resX" into "Debug\VT_Console.Form1.resources".
1>ResourceCompile:
1>  All outputs are up-to-date.
1>Link:
1>  VT_Console.vcxproj -> C:\SBSB\systems\debug\VT_Console.exe
1>PostBuildEvent:
1>          1 file(s) copied.
1>FinalizeBuildStatus:
1>  Deleting file "Debug\VT_Console.unsuccessfulbuild".
1>  Touching "Debug\VT_Console.lastbuildstate".
1>
1>Build succeeded.
1>
1>Time Elapsed 00:00:05.77
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========


This is app.config:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
  <connectionStrings>
    <add name="SQLConnection"
    connectionString="Server=localhost;
                      user id=root;
                      password=ghxxxxxx;
                      persist security info=True;
                      database=vendatic"
    providerName="System.Data.SqlClient" />
  </connectionStrings>
  <!--For COM Interfacing-->
  <!--ComConnection User="root" Password="ghxxxxxx" Host="localhost" database="vendatic" /-->
  <!-- Consider removing from released version-->
  <!--system.windows.forms jitDebugging="true" /-->
</configuration>


Adding the following to app.config made no differance:
<runtime>
  <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
    <dependentAssembly>
      <assemblyIdentity name="MySql.Data" publicKeyToken="c5687fc88969c44d" />
      <bindingRedirect oldVersion="6.3.6.0"
      newVersion="6.4.4.0" />
    </dependentAssembly>
  </assemblyBinding>
</runtime>


I am going to leave this unsolved for now, but at this stage, I have found reference online to this behaviour in the pre release days of VS2005 where it was acknowledged as a bug! As a workaround I put 6.3.6 on the machine alongside 6.4.4 - ugly but it gets me passed the problem
Posted
Updated 26-Feb-12 21:38pm
v4

1 solution

Do the following:

1) Clear the GAC of everything related to your projects.
2) Open your projects one by one (the .xxproj file) and check the HintPath points to a valid path if not fix the paths.
3) Rebuild your projects
 
Share this answer
 
Comments
Mukunda Raj 23-Jan-13 0:26am    
how to clear GAC??
Mehdi Gholam 23-Jan-13 1:14am    
Press WinKey+R then type assembly, an explorer windows will show you the contents of the GAC, delete anything related to MySql.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900