I use UIAutomationClient.dll in a Framework project which I'm moving to Core. This will only be on Windows so it's OK. But I need to reference it in way that can be run on differenet windows machines. There is a nuget package for this, commented that it should not be referenced directly. So how do I get it? If I go ahead and choose it, I get the error:
package type DotnetPlatform that is incompatible with this project
Please note: this is a console application which does some UI automating. It's not a desktop app, not WPF.
As vatsan-madhavan wrote on GitHub, you can use:
<ItemGroup>
<FrameworkReference Include="Microsoft.WindowsDesktop.App.Wpf" />
</ItemGroup>
Learning from all the problems with the BCL packages in .NET Core 1.x and 2.x, starting from .NET Core 3.0, the .NET Core SDK and NuGet support FrameworkReference
, which does not use version numbers (the SDK tells NuGet which version to download). Since it's so new, it's not well known, or frequently documented.
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