Help!

Sep 29, 2012 at 5:02 AM

Can someone help me with this error?

 

Could not load file or assembly 'System.Data.SqlServerCe, Version=4.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

Coordinator
Sep 29, 2012 at 6:06 AM

If you using Sql Server CE, you might look here.

Sep 29, 2012 at 6:27 AM
Edited Sep 29, 2012 at 6:28 AM

Thanks, I am using Sql Server Ce and the link answer you submitted is way over my head.  Everything was working fine, not sure what I did to break it.  It works locally but not on the server.

Sep 29, 2012 at 12:45 PM

I have uploaded the Sql Server Ce database, replaced all the dll's required for it and still receive the same error message.  Can anyone offer me some help to get this working again, it does work locally,  

Sep 29, 2012 at 1:20 PM

I am getting desperate, 4 hours sleep last night, I am willing to pay someone for help getting this fixed, I am at a loss as to what to do next!

Sep 29, 2012 at 7:09 PM

Does anyone have an idea why this is occuring?  Im am at a loos on how to fix this, please help if you can.

I have the sdf in the app data folder and the bin looks like this.

/bin

   System.Data.SqlServerCe.dll

/bin/x86

   sqlceca40.dll 

   sqlcecompact40.dll 

   sqlceer40EN.dll 

   sqlceme40.dll 

   sqlceqp40.dll 

   sqlcese40.dll 

/bin/amd64 

   sqlceca40.dll 

   sqlcecompact40.dll 

   sqlceer40EN.dll 

   sqlceme40.dll 

   sqlceqp40.dll 

   sqlcese40.dll 

Coordinator
Sep 29, 2012 at 7:37 PM

When you compile application that references System.Data.SqlServerCe.dll, it knows only CE version it was compiled with, which is your local version. On the servers they have different CE version used globally, so it trumps one you have in /bin and trying to use global CE. Because version does not match, it fails and shows this error. Link I gave you shows how to set mapping in web.config to tell that it is ok to use that global CE, even if version is different.

Sep 29, 2012 at 7:45 PM

Do I ad it to the existing web.config or do I have to create a new one with just that info and put it in the bin folder?

Sep 29, 2012 at 7:52 PM

I can understand this if I am trying to use a new hoster which I am trying to get setup but this error also now occurs on my current hoster, I must have screwed something up syncing files, they are probably using the correct version as it worked fine before all this mess happened and the error occurs there also.  I will update my web.config and upload it  to the new host and see what happens.

Sep 29, 2012 at 8:04 PM

Well I tried it on both servers and now receive this:

500 - Internal server error.

There is a problem with the resource you are looking for, and it cannot be displayed.

Sep 29, 2012 at 8:37 PM

New development on the new hosting server, I used the web.config from the SQLServerCE folder in setup and the site loaded.  This is the strange part, it is reading the current posts from the database but it will not allow me to login.  The 500 error still exists on the current host server with this web.config.  So the database seems to load somewhat on the new server but something still is not right as I cannot login.

Coordinator
Sep 30, 2012 at 10:46 AM

Before, I remember you had switched to clear text passwords (from hashed passwords).  I'm not sure if that's the case on this site you are working on, or if that was a different site.  When you switched to the Web.config file in the SQLServerCE folder, that is probably using the default which is hashed passwords.  If the passwords stored in your be_Users table are plain text, then you probably need to adjust your Web.config file to tell it to use clear text passwords again.

<add name="DbMembershipProvider" type="BlogEngine.Core.Providers.DbMembershipProvider, BlogEngine.Core"
passwordFormat="clear" connectionStringName="BlogEngine"/>

I'm assuming too that your "defaultProvider" is DbMembershipProvider, which means it would use the be_Users table.

Sep 30, 2012 at 12:38 PM

Hi Ben,

Yes, the first thing I did was change it to clear passwords.

I have pretty much given up on the old server and am now trying to get everything going on the new host server.  Still having the can't see the users issue.

Thank you