【问题标题】:Change focus on the infragistics ultra grid?改变对基础设施超网格的关注?
【发布时间】:2016-06-16 14:22:41
【问题描述】:

我想改变我的网格单元格的焦点。

假设我点击一个cell[1,1],然后我想将焦点设置在cell[1,2]上。

cell[1,1] 表示(第 1 列)和(第 1 行)的单元格

【问题讨论】:

    标签: c# .net infragistics ultrawingrid


    【解决方案1】:

    您可以使用 AfterCellActivate 事件并编写此代码

    void grid_AfterCellActivate(object sender, EventArgs e)
    {
        if (grid.ActiveCell != null && 
            grid.ActiveCell.Column.Index == 1 && 
            grid.ActiveCell.Row.Index == 1)
        {
            grid.ActiveCell = grid.Rows[1].Cells[2];
    
            // And if you want also to automatically 
            // put your cell in edit mode add this line
            grid.PerformAction(UltraGridAction.EnterEditMode);
        }
    
    }
    

    【讨论】:

      猜你喜欢
      • 2013-03-07
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-03-29
      • 2018-02-02
      相关资源
      最近更新 更多