What does it really mean to target a framework, and how do I maximize compatibility?

后端 未结 4 1336
花落未央
花落未央 2020-12-25 09:59

Greetings all,

This has confused me ever since I first started coding in C#. My goal is to create an assembly that will run on the most recent .NET framework the us

4条回答
  •  臣服心动
    2020-12-25 10:29

    Here is how targeting works: If you target .NET 3.5, it will not run if user does not have .NET 3.5. It will run if user has any higher version.

    For maximum compatibility, choose .NET 2.0, it will run even on .NET 3.5, 4.0 and so on.

    However, you might loose out on new features of .NET such as LINQ etc.

    http://msdn.microsoft.com/en-us/library/bb398197(VS.100).aspx

    Can I still target .NET Framework 2.0 in VisualStudio 2010?

提交回复
热议问题