[FIX] Visual Studio 2022 + 2026: Warning CA1416 "Call site reachable by all platforms" but "only supported on: 'windows'"
Edit your vb or cs project
ex: Viewer.vbproj
or Viewer.csproj
Check that the framework has the suffix "-windows" as the following example:
<TargetFramework>net10.0-windows</TargetFramework>
Then make sure that GenerateAssemblyInfo the following is set to true
<GenerateAssemblyInfo>true</GenerateAssemblyInfo>
Rebuild your project.
Comments
Post a Comment