Relative Content

Tag Archive for c#dllimportmef.net-8.0system.composition

Loading native dependencies for an MEF plugin

I have a .NET 8.0 application using MEF (System.Composition) as its plugin architecture. Most of the plugins work properly however there are a couple that will throw exceptions at runtime. Both of these plugins have one thing in common, they rely on libraries that use native dlls from a “runtime” folder. One has Microsoft.Web.WebView2 and the other has LiveCharts2, which uses Skia. They have “runtime” trees that look like this (e.g. for the livecharts plugin):