none
How to handle: Net framework 3.5 SP1 application fails to run on .NET framework 4.0. RRS feed

  • Question

  • We have the issue with our .NET 3.5 SP1 application described in the post below... it won't run or install if a user only has .NET 4.0 installed and no other Framework version.

    http://social.msdn.microsoft.com/Forums/en-US/netfxsetup/thread/4f0b7821-506f-453f-896e-54a545c75081

     The solution apparently is to add the following to app cofig:

    <SUPPORTEDRUNTIME version="v4.0" />

    Adding the app.cofing entry is a possibility if the program is already installed, but we have a requirement in our deployment project for .NET 3.5 SP1 and when only .NET 4.0 is installed the installer asks the user to download 3.5 SP1.

    So what is the best way to allow a user using .NET 4.0 only to run an app built against .NET 3.5 SP1 without possibly having them download .NET 3.5 SP1?  We would not have an issue if this was an individual (we would have them download .NET 3.5 SP1), but we have entire companies who have choosen to only have .NET 4.0 running and they don't want to change their images to add a component if they don't have to.

    We also have contracts in which will not allow us to upgrade our software to .NET 4.0 either.  Do they need the entire Framework or just the older runtime?  Lots of questions and I'm just looking for the best way to handle this.  Any suggestions would be appreciated.  Thanks!

    Thanks! 

    Friday, May 27, 2011 9:30 PM

Answers

  • Hi ToadRW

    Thanks for your post.

    First, there are some background information I would like to introduce:

    • The .NET Framework 2.0, 3.0, 3.5 uses the same CLR 2.0, and .NET Framework 3.0, 3.5 are essentially extenions of .NET Framework 2.0 with some new features. In addition, .NET Framework 3.5 installs .NET Framework 2.0 SP1, (installs .NET Framework 2.0 SP2 with 3.5 SP1) and .NET Framework 3.0 SP1 (installs .NET Framework 3.0 SP2 with 3.5 SP1).
    • The .NET Framework 4.0 is a complete Framework uses CLR 4.0, it can be installed side-by-side with .NET Framework 3.5.
    • Windows Vista, Server 2008 and 7 will install some versions of the .NET Framework automatically as system components. For example, Windows 7 will install .NET Framework 3.5 SP1 by default.

    For more information, please see: http://msdn.microsoft.com/en-us/library/bb822049.aspx

    Regarding your issue, as far as I know, there does not have a good workaround to resolve this issue so far. You can cosider change the target .NET Framework version and complie your applicaion for both .NET Framework 3.5 and .NET Framework 4.0. However, this might requires more work on debugging, testing your applications.

    You can submit this suggestion to Microsoft Connect feedback Center in formal format. Microsoft engineers will evaluate them seriously and report to Product Group. http://connect.microsoft.com/VisualStudio/

    In your feedback, you can quote the URL to this thread, so that the whole conversation can be available. Every feedback submitted will be evaluated carefully by our engineers. They will let you know their comments further through that portal. It would be great if you can also paste the link to the submitted feedback here, so that other community members can see it as well.

    If you need further assistance, feel free to let me know. I will be more than happy to be of assistance.

    Best Regards,


    Andrew Wu [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.


    Monday, May 30, 2011 10:08 AM
    Moderator

All replies

  • Hi ToadRW,

    As per your situation what it sounds is that you want to run .NET 3.5 Application on .NET 4.0 Framework application platform installed.

    If you are using Visual Studio 2010 or VS 2008,

    Just Select Your Project --> Project Menu --> Select ProjectName Properties --> In The Application Tab ---> Select Target Framework As .NET Framework 3.5 OR .NET Framework 3.5 Client Profile --> Build Your Application --> Then It will start running for Framework 3.5

    Also you use the <SupportedRuntime Version="v3.5"> in the App.Config file

    Reason For above solution is that : .NET Framework 4.0

    PLEASE PERFORM YOUR CHANGES ON A COPY OF YOUR PROJECT THEN TRY IT....

    PLEASE INFORM ON THIS BLOG IF THIS SOLUTION WORKS....

    Thanks,

    ------------------------------------------------------------------------------------------------------------------------------------------------------------------------

    CEO AT SRDTECHNOTRONICSGROUP

     

    • Proposed as answer by Ruzi Bhornan Sunday, May 29, 2011 7:26 AM
    Sunday, May 29, 2011 7:26 AM
  • Hi ToadRW

    Thanks for your post.

    First, there are some background information I would like to introduce:

    • The .NET Framework 2.0, 3.0, 3.5 uses the same CLR 2.0, and .NET Framework 3.0, 3.5 are essentially extenions of .NET Framework 2.0 with some new features. In addition, .NET Framework 3.5 installs .NET Framework 2.0 SP1, (installs .NET Framework 2.0 SP2 with 3.5 SP1) and .NET Framework 3.0 SP1 (installs .NET Framework 3.0 SP2 with 3.5 SP1).
    • The .NET Framework 4.0 is a complete Framework uses CLR 4.0, it can be installed side-by-side with .NET Framework 3.5.
    • Windows Vista, Server 2008 and 7 will install some versions of the .NET Framework automatically as system components. For example, Windows 7 will install .NET Framework 3.5 SP1 by default.

    For more information, please see: http://msdn.microsoft.com/en-us/library/bb822049.aspx

    Regarding your issue, as far as I know, there does not have a good workaround to resolve this issue so far. You can cosider change the target .NET Framework version and complie your applicaion for both .NET Framework 3.5 and .NET Framework 4.0. However, this might requires more work on debugging, testing your applications.

    You can submit this suggestion to Microsoft Connect feedback Center in formal format. Microsoft engineers will evaluate them seriously and report to Product Group. http://connect.microsoft.com/VisualStudio/

    In your feedback, you can quote the URL to this thread, so that the whole conversation can be available. Every feedback submitted will be evaluated carefully by our engineers. They will let you know their comments further through that portal. It would be great if you can also paste the link to the submitted feedback here, so that other community members can see it as well.

    If you need further assistance, feel free to let me know. I will be more than happy to be of assistance.

    Best Regards,


    Andrew Wu [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.


    Monday, May 30, 2011 10:08 AM
    Moderator
  • Hi ToadRw,

    We have not heard from you in a couple of days. Would you mind letting me know the result of the suggestions?

    If you need further assistance, feel free to let me know. I will be more than happy to be of assistance.

    Best Regards,


    Andrew Wu [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Wednesday, June 1, 2011 10:43 AM
    Moderator