开发者

Library namespace becomes unknown after manual update

开发者 https://www.devze.com 2023-01-12 03:13 出处:网络
I recently faced an issue with a third-party DLL we use in one of our ASP.NET websites. When I need to update it, I download a newer version from vendor\'s website and just replace the binary in the

I recently faced an issue with a third-party DLL we use in one of our ASP.NET websites.

When I need to update it, I download a newer version from vendor's website and just replace the binary in the "bin" folder in the website folder. Immediately Visual Studio loses this library's namespace (says the method is not accessible due to protection level). And recently we started getting random "Unable to compile" exceptions from the site, we开发者_Python百科 connect it with the library.

But if I delete the old library from the solution explorer, and then Add Reference to the newer version, everything works perfectly.

Is it a bug of Visual Studio, the library we use or our site? Has anyone ever faced same issue and knows how to fix it?

We use VS 2010, .NET 4.0 on Win7 Pro x64, TFS'10. The project is a VB.NET website (not web application).

Appreciate any help,

Tim


This is possible with strongly named assemblies - the previous version would have different name than the newer one. Once you replace the file, old referenced assembly is simply not available, so refreshing the reference in VS does the trick.

0

精彩评论

暂无评论...
验证码 换一张
取 消