Reference an assembly in visual studio 2003 that was created in visual studio 2005

Posted on 2006-04-20
Last Modified: 2008-02-01
   I have an assembly that I created in Visual Studio 2005.  It is created in the directory c:\logging\bin\Release\logging.dll.  I wish to use this assembly in visual studio 2003.  When I try to add a reference to it I browse to it, select the file and then get "A referenct to 'c:\logging\bin\Release\logging.dll' could not be added.  This is not a valid assembly or COM component.  Only assemblies with extension 'dll' and COM components can be referenced.  Please make sure that the file is accessible, and that it is a valid assembly or COM component"  In other VS 2005 solutions I have added the "Logging" project and then set a project reference.  Obviously with 2003 that is a problem.  Any suggestions would be greatly appreciated.

Question by:wildrobo
    LVL 69

    Expert Comment

    by:Éric Moreau
    Hi wildrobo,

    I never a way. I even saw someone trying to use COM to use the 2005 dll without success.

    LVL 11

    Accepted Solution

    Copy the code out and put it into a vs2003 project, fix where needed and then rebuild.

    Author Comment

    I do appreciate that, but the purpose I built the component for was not to have to maintain different code bases.  I guess if that is the only way to do it, I should create it in VS2003 because it would be compatible with 2005 then right?
    LVL 11

    Expert Comment

    Correct, not sure why they couldn't get the compatability to run both ways, some sort of dotnet wrapper or something, but 2005 can use 2003 but 2003 cant use 2005 (type thing).  Perhaps they will release a service pack later to sort it out.  Although to be honest by the time they do that most ppl will be used to working around the problem.
    LVL 69

    Expert Comment

    by:Éric Moreau
    >>I should create it in VS2003 because it would be compatible with 2005 then right?

    Yes. It is very stupid not to be able to use vs2005 from vs2003. It stops us doing incremental upgrades.

    Featured Post

    6 Surprising Benefits of Threat Intelligence

    All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

    Join & Write a Comment

    Introduction As chip makers focus on adding processor cores over increasing clock speed, developers need to utilize the features of modern CPUs.  One of the ways we can do this is by implementing parallel algorithms in our software.   One recent…
    The ECB site provides FX rates for major currencies since its inception in 1999 in the form of an XML feed. The files have the following format (reducted for brevity) (CODE) There are three files available HERE (…
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
    In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor ( If you're interested in additional methods for monitoring bandwidt…

    728 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now