3

(If that is even possible, of course; as of writing this, I am using the EAP 19 version, which is the latest release at the moment)

I have a WPF project where I am trying to pair a XAML and a XAML.CS file together since they're both parts of the definition of a partial class (as far as I understand it, at least).

However, no matter what I do, I cannot get Rider to understand they are linked.

Project explorer view

Here you can see Details.xaml.cs being neatly nested in Details.xaml, since Rider understands they're dependant, but no dice for CompendiumSearch.

Details and CompendiumSearch have virtually identical code, save for the class names of course.


PS: App and Details were created with VS, this is an old project I imported in Rider to build upon it; that's why they're already neatly nested.

Linkyu
  • 200
  • 3
  • 9
  • I cannot check at the moment, but if I'm not mistaken, the EAP 21 had already started supporting XAML files, so this might not be an issue anymore, but that's to be confirmed. – Linkyu Oct 17 '17 at 12:36

1 Answers1

2

EDIT : since this outdated question has recently received more attention, I feel obligated to point out that not only has the issue been resolved last year in the 2017.1 version (IIRC), but a visual previewer is set to be released in the 2018.1 version (current status has it ready for EAP 3).


The only way I found how to do it is by editing the .csproj file and adding these:

<Page Include="CompendiumSearch.xaml">
  <Generator>MSBuild:Compile</Generator>
  <SubType>Designer</SubType>
</Page>
<Compile Include="CompendiumSearch.xaml.cs">
  <DependentUpon>CompendiumSearch.xaml</DependentUpon>
  <SubType>Code</SubType>
</Compile>

However, as far as I know, editing the .csproj by hand is simply asking for trouble so I doubt this is the ideal solution.

Linkyu
  • 200
  • 3
  • 9