"Could not load file or assembly" error VB.NET
Posted on 2012-03-22
I have a VB.NET project that cannot be built on one particular PC with one particular DLL. The details:
1) I migrated a project to a new Win 7 64 PC (VS 2008).
2) When trying to build, it generates an error:
Cannot register assembly "XXX.dll". Could not load file or assembly 'XXX, Version=3.0.2000.0, Culture=neutral, PublicKeyToken=798276055709c98a' or one of its dependencies. One or more arguments are invalid (Exception from HRESULT: 0x80000003)
3) I have another version of that DLL XXX.dll, which works fine on that "Bad PC".
4) Both versions of XXX.dll work fine on any other PCs (about 50 tested) except that "Bad PC"
5) Only one version of XXX.dll works on a "Bad PC"
6) .NET configurations are identical on ALL machines.
7) VS references on a "Bad PC" point to the same libraries with the same versions
8) I tried to decompile that XXX.dll with Reflector and it shows references to the same dependent libraries - for both versions:
All the dependencies' versions are the same for both XXX.dll libraries.
My question: what could prevent running one of the versions of that XXX.dll on a "Bad PC"? That XXX.dll is for .NET 2.0, quite old one.