#region 显示行号
private void treeList1_CustomDrawNodeIndicator(object sender, DevExpress.XtraTreeList.CustomDrawNodeIndicatorEventArgs e)
{
DevExpress.XtraTreeList.TreeList tmpTree = sender as DevExpress.XtraTreeList.TreeList;
DevExpress.Utils.Drawing.IndicatorObjectInfoArgs args = e.ObjectArgs as DevExpress.Utils.Drawing.IndicatorObjectInfoArgs;
if (args != null)
{
int rowNum = tmpTree.GetVisibleIndexByNode(e.Node) + 1;
args.DisplayText = rowNum.ToString();
}
e.ImageIndex = -1;
}
#endregion
Dev Treelist控件显示行号
最新推荐文章于 2024-09-03 11:44:07 发布
本文详细介绍了如何在 DevExpress TreeList 控件中自定义节点指示器,使其显示当前节点所在的行号。
2574

被折叠的 条评论
为什么被折叠?



