running .net 3.5 apps on .net 4 RRS feed

  • Question

  • Im building a WPF application which is targeting the .net 3.5 framework and is being bulit on a system which has 3.5 installed but not 4.0.
    Is there any way I can run the application on a machine which has only .net 4 installed and no .net 3.5 installed??
    Currently it is giving me a FileNotFoundException for System.Core v- Can it be somehow made to reference the latest System.Core??


    Tuesday, February 16, 2010 7:50 AM


  • Absolutely.

    You can target your existing .NET apps to use .NET 4. To your application configuration file <AppName>.exe.config (i am assuming you app has one), please add the section within the configuation section (bold). If you dont have an app.config file, create one and add the whole thing below.

        <supportedRuntime version="v4.0" />

    Thus you can force the app to use .NET 4
    • Marked as answer by YiChun Chen Tuesday, February 16, 2010 8:35 AM
    Tuesday, February 16, 2010 8:01 AM