Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rx 5 preview missing DispatcherScheduler.Current for WPF net5.0? #1315

Closed
tomasfabian opened this issue Sep 28, 2020 · 3 comments
Closed

Rx 5 preview missing DispatcherScheduler.Current for WPF net5.0? #1315

tomasfabian opened this issue Sep 28, 2020 · 3 comments

Comments

@tomasfabian
Copy link

I tried the preview version of Rx and it seems that System.Reactive.Concurrency.DispatcherScheduler.Current is not available for WPF net5.0 RC1. For NetCoreApp 3.1 it works correctly.

<Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">

  <PropertyGroup>
    <OutputType>WinExe</OutputType>
    <TargetFrameworks>net5.0-windows;netcoreapp3.1</TargetFrameworks>
    <UseWPF>true</UseWPF>
  </PropertyGroup>

  <ItemGroup>
    <PackageReference Include="System.Reactive" Version="5.0.0-preview.16" />
  </ItemGroup>

</Project>

Based on this commit the HAS_WPF constant should be defined: db8e159

My dotnet version is 5.0.100-rc.1.20452.10. I'm using VS 16.8.0 Preview 3.1.

What am I doing wrong?

Thank you Tomas

@clairernovotny
Copy link
Member

You must use the 19041 SDK. Your .NET 5 TFM must be net5.0-windows10.0.19041. You can target a lower version by setting a min version.

@tomasfabian
Copy link
Author

Interesting. Thank you @clairernovotny for you quick response/advice

@ekgurney14
Copy link

Does anybody know why we need to use the 19041 SDK for this capability?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants