0

I have my project created in Asp.Net 4.5 Mvc 5 C#. I'm using Asp.Net Identity for login and signup. I published this app from visual studio. soon after i'm getting this error whenever i try to login or register. all else is working fine.

enter image description here

What have i tried -

  • I try to clean build rebuild solution many times
  • I try to restrat visual studio.
  • I try to clean release debug solution many times.
  • deleting all dll from bin folder and build solution again.

but none of these solution seems to be working. Any help will be appiciated.

Vikas Rana
  • 1,961
  • 2
  • 32
  • 49
  • Is the assembly referenced and is the *CopyLocal* property of the assembly set to *True*? Does the error go away if you copy the assembly manually to the server? – Dirk Vollmar Jan 04 '16 at 15:41
  • The indicated assembly is missing. You need to make sure that it is in the bin folder. If CopyLocal is not working then you need to copy it manually. I've had situations in the past where the project is referenced, copy local is selected and it still didn't copy on publish. I would get the same issue as you. Then i copy the missing assembly into folder and it works. – Nkosi Jan 05 '16 at 01:06

2 Answers2

0

Ok this looks like you are referencing different versions of assemblies.

One reason could be that .Net picking wrong referenced assembly version

If you are using a layered architecture then make sure that your main project and other projects referencing Entity Framework are using the same version.

Community
  • 1
  • 1
Nkosi
  • 235,767
  • 35
  • 427
  • 472
0

Dont know why but changing database works for me. I just changes connection string to connect another backup copy of database and it starts working fine.

Vikas Rana
  • 1,961
  • 2
  • 32
  • 49