Hi I create one WPF application using .Net 5.0 . It is working fine in my dev system .
But when i try to copy and run bin folder to my windows 7 system , It is giving below error :
The framework 'Microsoft.WindowsDesktop.App', version '5.0.0' was not found.
But still getting error .
Update :
But Self contained package working fine .
NET 5 is an open-source, cross-platform . NET framework, that will replace . Net Framework, . Net Core, and Xamarin with a single unified platform. .
Unless your application has specific reasons for earlier SDKs or runtimes, you may safely remove older versions.
.NET Desktop Runtime 7.0.0 The .NET Desktop Runtime enables you to run existing Windows desktop applications. This release includes the .NET Runtime; you don't need to install it separately.
This condition is caused by the fact that your other machine may not have the required .NET 5.0.7 Desktop runtime to run your .NET 5.0 WPF app.
On the official page to download .NET 5.0, each SDK and related runtime version has its own notes. If you only install .NET 5.0 runtime, it won't install the related .NET 5.0 Desktop runtime to support WPF and Windows Forms.
For example:
That picture shows that you still have to install .NET 5.0.7 Desktop Runtime manually after you install .NET 5.0.7 runtime.
Therefore to fix your problem, you have to install .NET 5.0.7 Desktop Runtime, not just installing .NET 5.0.7 Runtime.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With