Telerik blogs
DotNetT2 Light_1200x303

The .NET Conf 2020 is now under way—join the livesteam where Scott Hanselman and Scott Hunter just demonstrated how the Telerik UI for WinForms controls work in the Visual Studio designer in a .NET 5.0 project! Let's all welcome the new future of .NET! 

.NET 5.0 Support

Telerik UI for WinForms demo at .NET ConfLive from .NET Conf: Scott Hanselman using Telerik UI for WinForms controls to demonstrate a .NET 5 app!

Microsoft has always been committed to desktop software development and they have been investing in it heavily. Just think of all the major performance improvements, the easy deployment options, Hot Reload and designer actions in WPF, the Visual Studio WinForms designer etc. The Telerik teams have tested all of the preview versions of .NET 5.0 and now we can confirm that .NET 5.0 is fully supported for our desktop UI libraries. We started shipping assemblies built against the preview versions of .NET 5.0 right after Microsoft Build in May 2020. Now you can use them with the official .NET 5.0.

Let's take a look at how easy it is to use .NET 5.0 in your projects. Here is a sample SDK-style project file:

<Project Sdk="Microsoft.NET.Sdk">
    <PropertyGroup>
        <OutputType>WinExe</OutputType>
        <TargetFramework>net5.0-windows</TargetFramework>
        <UseWindowsForms>true</UseWindowsForms>
    </PropertyGroup>
    <ItemGroup>
        <PackageReference Include="UI.for.WinForms.AllControls.Net50" Version="2020.3.1020" />
    </ItemGroup>
</Project>

Note that the SDK project type has changed in .NET 5.0. It is no longer necessary to specify WindowsDesktop, just use: Sdk="Microsoft.NET.Sdk.  For WinForms and WPF, it is necessary to specify the target framework with an OS binding: net5.0-windows. This way you will explicitly declare that the application will run on Windows 🤷‍♂️😲🤷‍♀️: https://docs.microsoft.com/en-us/dotnet/standard/frameworks#net-5-os-specific-tfms.

As for our controls, the easiest way to use them in .NET 5.0 is via our NuGet packages: https://docs.telerik.com/devtools/winforms/visual-studio-integration/install-using-nuget. The packages with a NET50 ending are built against .NET 5.0 and the AllControls package in the above sample contains all of our UI controls as well as the Document Processing libraries.

WinForms Designer

Telerik UI for WinForms is the first control suite in the world to have support for Visual Studio design-time in .NET Core/NET 5.0. We released our designers for the first time in our R3 2020 release which was in mid-September. We are very proud of this fact and we encourage you to test the controls in .NET Core 3.1 or .NET 5.0 design-time environment. The WinForms designers are implemented as part of our NuGet packages, so you will need to install a Telerik UI for WinForms package in Visual Studio in order to use them.

net5.0-designer

Head over to our documentation for more details on the design-time support in .NET Core and .NET 5.0: https://docs.telerik.com/devtools/winforms/core/design-time.

Happy designing!

🎨🎉😊

Try it Out

You want to build your next desktop application? Make sure you use controls that are fully compatible with .NET 5 - try the latest version of Telerik UI for WinForms and Telerik UI for WPF to explore all the new features and themes.

We'd love to hear how this all works for you, so please let us know your thoughts by visiting our Feedback portal or by leaving a comment below.

 


Hristo Merdjanov
About the Author

Hristo Merdjanov

Hristo joined the company in 2014 after graduating from Telerik Academy. He has been part of the WinForms team ever since. Hristo is passionate about the native technologies and WinForms in particular. Besides programming Hristo loves travelling, especially to the beach. He is also a keen tennis player.

Related Posts

Comments

Comments are disabled in preview mode.