How do you use the 26100 SDK with .NET?

yoyodyne01 61 Reputation points
2024-06-21T20:42:25.8866667+00:00

Using the latest visual studio, all current updates, build system is OS version 22621, deploying to OS version 26100. 26100 SDK is installed from Visual Studio installer.

  1. Create a blank "WPF Application" project from Visual Studio
  2. Target .NET 6.0
  3. Add TFM <TargetFramework>net6.0-windows10.0.26100.1</TargetFramework> to the project file.

Build error is
error NETSDK1140: 10.0.26100.1 is not a valid TargetPlatformVersion for Windows. Valid versions include: ...

.NET
.NET
Microsoft Technologies based on the .NET software framework.
3,808 questions
Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,762 questions
{count} votes

2 answers

Sort by: Most helpful
  1. yoyodyne01 61 Reputation points
    2024-06-25T18:07:10.4066667+00:00

    The answer is to add this to the project file

    	<ItemGroup>
    		<WindowsSdkSupportedTargetPlatformVersion Include="10.0.26100.1" WindowsSdkPackageVersion="10.0.26100.1" MinimumNETVersion="6.0" />
    		<SdkSupportedTargetPlatformVersion Include="10.0.26100.1" />
    	</ItemGroup>
    

    VS hasn't been updated yet for the 26100 SDK.

    2 people found this answer helpful.

  2. Hongrui Yu-MSFT 1,605 Reputation points Microsoft Vendor
    2024-06-24T06:11:28.37+00:00

    Hi,@yoyodyne01. Welcome to Microsoft Q&A. 

    Reason:

    10.0.26100.1 in <TargetFramework>net6.0-windows10.0.26100.1</TargetFramework> is not a valid TargetPlatformVersion for Windows

     

    Solution:

    1.The simplest way is to use the following code:

    
    <TargetFramework>net6.0-windows</TargetFramework>
    
    

     

    2.Use a valid version

    10.0.22621.0

    10.0.22000.0

    10.0.20348.0

    10.0.19041.0

    10.0.18362.0

    10.0.17763.0

    8.0

    7.0


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

     

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.