Can i use .dll library targeted .net framework v3.5 in application having targeted framework 4.0? - wpf

Hello currently I'm working on desktop application using WPF. I create application by targeting .net framework 4.0. but I have facing some problems related targeted frameworks.
First there is a library which i have to use in my application.A library supports targeted .net framework v3.5 but I also want to use the DataGrid control (only available above than v4.0 targeted .net framework) for table so now i'm confuse what i should do now? how can i achieve my goal? i want to use both library + Datagrid control in my application which is targeting .net framework v4.0.
Thanks in advance :)

Related

about ef core winforms net framework support problem

I want to develop a general project, the desktop application must be .Net Framework and I will use EF Core 5.0 in the background and the libraries must be .net standard so that they are compatible with xamarin and Asp.net Core. Everything is fine, but the net framework does not support 2.1. How do I overcome this problem?.
NET 5.0 desktop toolbox has problems. I am someone who uses Devexpress and it does not come out in vehicles. I asked Devexpress and they said they have microsoft-side problems. I didn't know what to do. Syncfusion components do not look the same, unfortunately :(
You have to develop Winforms application using .NET 5. It is replacement of .NET Framework which become deprecated.
https://learn.microsoft.com/en-us/dotnet/desktop/winforms/?view=netdesktop-5.0

What versions of .NET and WPF, does the ModernUI framework support?

I'm working with a WPF app that was written using the ModernUI framework. I'm wondering what versions of the .NET Framework does the ModernUI support?
The ModernUI assemblies target .NET Framework 4.5 which means that the library is compatible with any version equal to or larger than 4.5.
You can confirm this by looking at the <TargetFrameworkVersion> elements in the .csproj files on GitHub:
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>

Dependency Injection in WPF and Asp.Net Core

I am using Asp.Net Core to write API Layer for one of my legacy application developed using WPF (.Net Framework 4.5). I have used https://www.nuget.org/packages/Microsoft.Extensions.DependencyInjection/ in Business layer which I want to access from WPF application. The version of this DI is not supported by .Net Framework 4.5 so I am unable to use it from WPF. Any suggestions how should I go with this ? The other approach is to use anyother DI container supported by .Net framework 4.5 and Asp.Net Core
I have upgraded my WPF project to .Net Framework 4.6 and rest of the layers are created using .Net Standard Library 2.0.

Consume .Net Core library from .Net standard project

I have a standard WPF application developed in .Net framework 4. Now, my client wants a website which I am planning to develop using .Net Core. In order to share the business logic, I need to move the database along business layer to a separate project and here I am planning to use .Net Core. So, all the layers i.e. Data/ Business/ API will be re-written using latest version of .Net Core.
Would I be able to reference business layer written in .Net Core from WPF (.Net Framework 4) project?
Any pointers will be highly appreciated.....
You should implement the common functionality in a .NET Standard library. You will then be able to reference this assembly from all apps that are compatible with the version of the .NET Standard that your common project targets.
The various .NET implementations target specific versions of .NET Standard and the following table on MSDN lists all versions of .NET Standard and the platforms supported: https://learn.microsoft.com/en-us/dotnet/standard/net-standard.
The latest version of .NET Core (currently 2.0 at the time of writing) implements .NET Standard 2.0. The oldest version of the .NET Framework that implements .NET Standard 2.0 is 4.6.1. This means that your WPF app should target 4.6.1 to be able to consume a .NET Standard 2.0 assembly.
.NET Core 1.0 and .NET Framework 4.5 support .NET Standard 1.0.
The .NET Framework 4.0 doesn't support any version of .NET Standard though so you should re-target your WPF app against (at least) .NET Framework 4.5.
Would I be able to reference business layer written in .Net Core from WPF (.Net Framework 4) project?
The answer is yes. You can try it: In Visual Studio create a WPF application project and a .NET Standard library project and then add a reference from the application project to the library project.
There will be NuGet packages that you cannot reference in your .NET Standard project because they only support full .NET Framework but most popular NuGet packages can be referenced from a .NET Standard project. Your question is also tagged [entity-framework-6]. If you want to use Entity Framework from a .NET Standard project you will have to use Entity Framework Core as Entity Framework 6 requires the full framework.
You should probably create a quick spike to determine if you can build your application how you intend to.

If the subset of the .NET framework is included in the Silverlight Plugin why does it not automtically work on Linux

If the subset of the .NET framework is included in the Silverlight Plugin why does it not automtically work on Linux?
You need to install Moonlight to run Silverlight applications on Linux

Resources