MySql.Data not found - web.config

Discussion in 'General troubleshooting' started by shavei7, Dec 13, 2010.

  1. Hi,

    I'm trying to load my website but I'm getting an error on my webconfig. Somebody suggested I copy my mysql.data.dll to my bin directory but it's a website and there's no bin directory.

    Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

    Parser Error Message: Could not load file or assembly 'MySql.Data, Version=5.1.5.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' or one of its dependencies. The system cannot find the file specified.

    Source Error:
    Line 37: <add assembly="System.Data.DataSetExtensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    Line 38: <add assembly="System.Xml.Linq, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    Line 39: <add assembly="MySql.Data, Version=5.1.5.0, Culture=neutral, PublicKeyToken=C5687FC88969C44D"/>
    Line 40: </assemblies>
    Line 41: </compilation>

    Any suggestions :confused: ? I'm hoping to get my website up by tomorrow
     
  2. Can somebody help? This is the only thing that's holding back my site from going up. If I change it back to 5.2.5.0 (which is what I have on my machine), then it works --- it's already connecting/pointing to mysql on discountasp.net. If I could just get this dll version to work....
     
  3. Bruce

    Bruce DiscountASP.NET Staff

  4. I know 5.1.5 is an old version but your support staff told me before that that's the version that you have. I have 5.2.5 which I downloaded just a few weeks ago. I've figured it out myself. Bin directory is not created by default in VS2008 for a web application. You have to manually add a BIN directory.
     
  5. Bruce

    Bruce DiscountASP.NET Staff

    cool
     
  6. I had the same issue. Another fix is to right click on MySql.Data in the references folder, click Properties, then set Copy Local to True.
     
  7. ...Good tip, that is the way to do it. ;-)
     

Share This Page