I read quite a few SO links and the 1000-page "Programming WPF" and things are not so working.
I have this in MainWindow.xaml
<Window.Resources>
<Cursor x:Key="rightArrowCursor">Resources/im_pane</Cursor>
<Style TargetType="DataGridRowHeader">
<Setter Property="Cursor" Value="{StaticResource rightArrowCursor}"/>
</Style>
and im_pane.cur
is added as existing file to Resources.
When the mouse is over DataGridRowHeader
, I get exception:
XamlParseException: Failed to create a 'Cursor' from the text 'Resources/im_pane' ... Requested value 'Resources/im_pane' was not found.
I also tried Properties/Resource/im_pane
, or im_pane.cur
, still got the same error.
I just wonder how you use custom cursor in XAML?