Upgrade to VB.net 2005 gives - the given assembly name or codebase was invalid

Just upgrading a VB.NET COM enabled DLL (class library) from VS 2003 to VS 2005

I am getting this error message...

Error 1 'The given assembly name or codebase was invalid. (Exception from HRESULT: 0x80131047)' C:\company5\BusClassNET04\LC companybusinessclass5

The file LC does not exist

Another similar project compiles OK so I am really confused as to why this is happening. I have tried shortening the assembly name. I don't really understand codebase but the text "codebase" does not occur in the entire project.

Any help would be appreciated

 



Answer this question

Upgrade to VB.net 2005 gives - the given assembly name or codebase was invalid

  • tripl3z3ro

    OK, I found the answer was in the licences.licx file. This file contained an invalid reference to a datadynamics activereports DLL, and that caused the error message even after I had removed.

    Might be worth raising a bug as the error message was very confusing.

     


  • arnie

    Thanks Rynus

  • snjvsax

    thanks Rynus

    i got the error in another project and then i unchecked 'Enable the Visual Studio hosting process', now it works fine, thanks again.


  • Pankaj Arora

    Merci c'est grandiose .. j'ai enfin trouve la solution a mon probleme et ce grace a toi
    I also had the same problem and now it ok

    thx


  • Marcio DTP

    error: The given assembly name or codebase was invalid. (Exception from HRESULT: 0x80131047)

    This is how I solved this problem: I deleted the bin folder and deleted the obj folder. Now it works fine.

    Martin


  • Bukhari

    Where is a complete list of Outlook development resources which I keep up to date .
  • Padmaja B

    i have this error in a C# project and i don't know what's the problem.
    i use C# express to an upgraded c#2003 project
    i deleted bin and obj folders and still the problem persists
    anyone knows what to do

  • Europa

    I got the same error when I tried to add a business object as datasource item. The problem was a class in my project which had three generic types. Got the same error with a blank soulution and only this empty class:

    Code Snippet
    class Class1<T, U, V> {}

    Remove one of the types and it works fine.


  • Babu2005

    Make sure your assembly name doesn't have a ' in it. As soon as I removed it, no more error. Happy programming.

  • R Pham

    I had that happen to me as well. I think that should be reported as a bug, they should have some sort of validation that stops you putting ' into an asemblies name.
  • James Clark

    I accidentally fixed this error, by disabling the checkbox 'Enable the Visual Studio hosting process' in the form

    Project > [Project_Name] Properties... > Debug

    works fine now for me =/



  • Raman Iyer

    i finally did it maually, i created a new empty project and copied the code from the 2003 project into the new project, i divide the code to follow the 2005 style and the code works perfect so it must be something with the upgrade engine.

  • C. Wells

    This exception suddenly cropped up on working code on the instantiation of a class within the same assembly. Making this error extremely ambiguous, at best.

    I tried Ryanus' solution of unchecking the Visual Studio hosting process checkbox, alas that didn't fix it right away. (I didn't try closing and opening the solution)

    However, deleting the bin & obj folders and then rebuilding did the trick.

    oh what a bug.

  • Anat Oren

    If you are getting compile errors you should try asking in the C# General forums instead of MSBuild. While we own the overall engine, the C# team is best at figuring out why your upgraded project won't build.

    Neil



  • Upgrade to VB.net 2005 gives - the given assembly name or codebase was invalid