在代码中设置排序时,ColumnHeader 的箭头不指向任何方向

发布于 2024-12-14 09:50:54 字数 286 浏览 2 评论 0原文

当在代码中将排序添加到 ListCollectionView 时,如下所示:

RowViewModelsView.SortDescriptions.Add(new SortDescription("FilterOrder", ListSortDirection.Ascending));

它将正常工作。然而,列标题上的实际箭头并不指向任何方向。仅当我自己实际单击列标题(并因此再次排序)时,这才有效。

我想我必须发出通知,但不知道在哪里显示箭头。

非常感谢,

When adding the sortings to A ListCollectionView in the code like this:

RowViewModelsView.SortDescriptions.Add(new SortDescription("FilterOrder", ListSortDirection.Ascending));

It will work fine. However the actual arrow on the column Header doesn't point to any direction. This only works if I actually click on the column header myself (and hence sort again).

I think I have to raise a notification, but have no idea where to get the arrows shown.

Many Thanks,

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

凡间太子 2024-12-21 09:50:54

试试这个:

Grid.Columns(indexColumn).HeaderCell.SortGlyphDirection

Try this:

Grid.Columns(indexColumn).HeaderCell.SortGlyphDirection
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文