hot33331
hot33331

Reputation: 841

Can I create a WPF application with .net 5 preview?

I am trying to create a .net 5 wpf application. Is this currently possible?

I Installed .net 5 sdk and the latest VS for Windows preview.

I cannot seem to find a template other than 4.x and .net core. This makes it seem like .NET 5 doesn't support this (yet)?

Is there a way to create a WPF application in .NET 5?

Upvotes: 5

Views: 7330

Answers (2)

hot33331
hot33331

Reputation: 841

Thanks for all the answers! To sum it all up: in the latest preview of Visual Studio for Windows I had to select WPF on .net core. With the WPF on .net (without core) I could only select 4.x and the .net core template already had .net 5 selected. There was no choosing which version from the template.

Upvotes: 0

ΩmegaMan
ΩmegaMan

Reputation: 31626

Is there a way to create a WPF application in .NET 5?

Yes install the Preview Version of Visual Studio which until release of .Net 5, is the only version of VS which can build this type of app.

Note that it can be installed side by side with non preview version Visual studio.


Preview Steps To Create

Create a WPF project and select .Net Core:

enter image description here

Then verify its the version by doing properties on the project:

enter image description here


Note even though on the properties pages, the version control will list previous versions of .Net. That implies one could change, but moving it back causes too many errors; so I do not advise to try to downgrade back with a .Net Core WPF app.

Upvotes: 4

Related Questions