DevExpress GridControl 显示行号、设置行号宽(转)

设置行号宽

gridView1.IndicatorWidth = 30;

显示行号

private void gridView1_CustomDrawRowIndicator(object sender, DevExpress.XtraGrid.Views.Grid.RowIndicatorCustomDrawEventArgs e)
{
if (e.Info.IsRowIndicator && e.RowHandle > -1)
{
e.Info.DisplayText = (e.RowHandle + 1).ToString();
}
}

上一篇:Devexpress GridControl开启内置底部导航栏


下一篇:html的xmlns属性