Microsoft Preview of .NET Core WinForms Designer Is 'Huge Technical Challenge'
Microsoft introduced the first preview of the .NET Core Windows Forms Designer, which didn't make it into the recent .NET Core 3.0 release because of the "huge technical challenge" in porting the Windows-only desktop technology to the new cross-platform framework.
NET Core 3.0 was a huge milestone for the company's new open source, cross-platform direction because it included formerly missing functionality such as Windows Forms and Windows Presentation Foundation (WPF) development support.
While the WPF designer was baked into Visual Studio 2019 16.3, released last week along with .NET Core 3.0, the Windows Forms designer was still in preview, available only as a Visual Studio extension (VSIX) download.
Yesterday, Sept. 30, Microsoft officially introduced the .NET Core Windows Forms Designer Preview 1.
"For developers the .NET Core Windows Forms Designer (when we will release the GA version) will look and feel the same as the .NET Framework Windows Forms Designer," said Olia Gavrysh, program manager, .NET. "But for us it is a huge technical challenge to bring the designer to .NET Core because it requires the design surface that hosts the live .NET Core form to run outside the Visual Studio process. That means we need to re-architect the way the designer surface 'communicates' with Visual Studio."
Speaking to the intense developer interest in desktop support in .NET Core, the post garnered an unusually large number (21 and counting today) of comments.
"Very nice, thank you!" read one comment. "I want to experiment with this alongside compiling the entire thing into a single trimmed-down EXE. Being able to ship a single binary that contains all dependencies is one of my favorite features of .NET Core 3. Being able to ship a single-binary WinForms application would definitely make deploying my software a lot easier.
"Sometimes there is nothing better than WinForms for tossing an idea together in an afternoon. I look forward to playing with the early bits, thanks for releasing it!"
The preview is still available only as a VSIX download (Note: clicking on link may initiate download). So it needs to be installed and then enabled, and then it will work with limited functionality.
"Please keep in mind, that this is the first preview, so the experience is limited," Gavrysh said. "We support the most commonly used controls and base operations and will be adding more in each new Preview version. Eventually, we will bring the .NET Core Designer at parity with the Windows Forms Designer for .NET Framework.
"Because many controls aren't yet supported in Preview 1 of the designer, we don't recommend porting your Windows Forms applications to .NET Core just yet if you need to use the designer on a regular basis. This Preview 1 is good for 'Hello World' scenarios of creating new projects with common controls."
While some 19 controls are available -- ranging from Button to TreeView -- features not making the support cut include:
- Component Tray
- In-place editing
- Designer Actions
- User Controls/Inherited Controls
Interested developers can read the post for answers to questions such as:
- What to do if Windows Forms Designer doesn't work?
- Does .NET Core WPF Designer depend on Windows Forms Designer installation?
More information on the preview is available in the release notes.
While Gavrysh asked for developer feedback, some was already provided in the post's comments.
"Mono had an incomplete port of Windows Forms, that ran on both Linux and MacOS," one comment noted. "Any chance of giving multiplatform Windows Forms leveraging the previous work on Mono to .NET core? It would be amazing if .NET 5 came with this working!"
David Ramel is an editor and writer for Converge360.