Assembly Microsoft.Owin not found

Asked

Viewed 1,886 times

1

In my project I am using the OWIN library for user authentication. I already installed the package, but when I run the project I return the error:

Could not load file or Assembly 'Microsoft.Owin, Version=2.1.0.0, Culture=neutral, Publickeytoken=31bf3856ad364e35' or one of its dependencies. The definition of the localized Assembly manifest does not correspond to the Assembly reference. (HRESULT exception: 0x80131040)

If anyone can help I’d appreciate it.

2 answers

2

Reinstall a newer version of Microsoft.Owin, this version is from and January 2014. Install version 3.0.1.

Update-Package Microsoft.Owin

Obs: Sometimes go into Import and Export Settings, and give a Reset all Settings solves the problem

  • 2

    Make a Clean Solution and delete all folders packages, obj and bin is also a common practice of forcing binaries to be recreated.

1

I had the same problem and the fix was:

Build -> Clean Solution, and Build -> Rebuild Solution

Before publishing. I deleted all files and then

Build -> Publish

Worked well for me (VS2017 / IIS 7)

Browser other questions tagged

You are not signed in. Login or sign up in order to post.