Use a Content File from a .NET Standard assembly in a WPF application
问题 I want to embed a file in a .NET Standard assembly and use it in XAML in a WPF app. If you set the build action to Resource it is very easy to use the embedded file in other assemblies, but you have to use <Project Sdk="Microsoft.NET.Sdk.WindowsDesktop"> and <UseWPF>true</UseWPF> to be able to use the Resource build action like so: <PropertyGroup> <TargetFramework>netcoreapp3.1</TargetFramework> <UseWPF>true</UseWPF> </PropertyGroup> <ItemGroup> <Resource Include="Resources\Image.png" /> <