Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. .NET (Core and Framework)
  4. Reference a .NET 3.5 assembly form a .NET 2.0 other assembly: in VS2008 ok, not in VS2010

Reference a .NET 3.5 assembly form a .NET 2.0 other assembly: in VS2008 ok, not in VS2010

Scheduled Pinned Locked Moved .NET (Core and Framework)
csharpasp-netvisual-studioquestion
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • F Offline
    F Offline
    Ferdinando Santacroce
    wrote on last edited by
    #1

    Good afternoon! :) Yesterday for me was the "Great day": new pc, new VS. I installed VS2010, and ported my solutions to it. In a solution of mine, I need to create a .NET 2.0 assembly (compatibility issues with ACU Cobol) that uses some other assemblies compiled with .NET 3.5 Warning messages apart, in VS2008 all works fine; in VS 2010 I cannot compile: my 2.0 project reference against other 3.5 appears with the warning yellow mark. I can comnpile only if I reference by hand System.Core.dll from .NET 3.5 framework in my 2.0 targeted assembly. Anybody can give me an explanation about this new/strange VS2010 behaviour? :(( Thanks! Nando ;)

    Jesus

    N 1 Reply Last reply
    0
    • F Ferdinando Santacroce

      Good afternoon! :) Yesterday for me was the "Great day": new pc, new VS. I installed VS2010, and ported my solutions to it. In a solution of mine, I need to create a .NET 2.0 assembly (compatibility issues with ACU Cobol) that uses some other assemblies compiled with .NET 3.5 Warning messages apart, in VS2008 all works fine; in VS 2010 I cannot compile: my 2.0 project reference against other 3.5 appears with the warning yellow mark. I can comnpile only if I reference by hand System.Core.dll from .NET 3.5 framework in my 2.0 targeted assembly. Anybody can give me an explanation about this new/strange VS2010 behaviour? :(( Thanks! Nando ;)

      Jesus

      N Offline
      N Offline
      Not Active
      wrote on last edited by
      #2

      I don't think this is new or strange. You obviously can't use upper versions of framework components from lower versions.


      I know the language. I've read a book. - _Madmatt

      L F 2 Replies Last reply
      0
      • N Not Active

        I don't think this is new or strange. You obviously can't use upper versions of framework components from lower versions.


        I know the language. I've read a book. - _Madmatt

        L Offline
        L Offline
        Luc Pattyn
        wrote on last edited by
        #3

        Actually I just had a similar experience: a solution with one 3.5 EXE project referencing two 2.0 DLL projects; it was created long ago with 2008 without any problem (initially it was all 2.0, but then the EXE needed some LINQ and I never got around to modify the DLL targets). When ported to VS2010 I had to modify the DLL projects so they now all target the same framework. :)

        Luc Pattyn [Forum Guidelines] [Why QA sucks] [My Articles]


        Prolific encyclopedia fixture proof-reader browser patron addict?
        We all depend on the beast below.


        1 Reply Last reply
        0
        • N Not Active

          I don't think this is new or strange. You obviously can't use upper versions of framework components from lower versions.


          I know the language. I've read a book. - _Madmatt

          F Offline
          F Offline
          Ferdinando Santacroce
          wrote on last edited by
          #4

          Yes, but why VS2008 did not make this a problem on compiling? I agree with you when you say you can't use upper framework form a 2.0 assembly, 'cause, for example it can be deployed on a win2000 or on a machine without .NET 3.0. But as I say in my previous post, I'll deploy this solution on .NET 3.5 ready machines; only a bug/limit of Cobol<->.NET bridge force me to compile only this Cobol-.NET-interface-assembly in 2.0. However, I found the trick: reference System.Core.dll (or other dll needed by your referenced assemblies) by hand. Thanks! Nando

          Jesus

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups