Problem
The target framework switch button is no longer visible in Rider, even though it was functional previously. Other IDEs, such as Visual Studio 2022, still allow switching the target framework within the same file. The project is defined in the .csproj file using multiple target frameworks with <TargetFrameworks> and Sdk="Microsoft.NET.Sdk".
Cause [Optional]
The quick switcher is only enabled when multiple SDK targets are selected in Rider. If multi-targeting is not set correctly in the project properties, the button will not appear in Rider.
Resolution
To enable the quick switcher for target frameworks in Rider:
-
Right-click the project node in the Solution Explorer and select Properties...
-
Ensure multiple target frameworks are defined here.

-
Go back to your project. The switch target framework button should now appear.

Comments
0 comments
Please sign in to leave a comment.