Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1510
why does the **cell** not enter **edit**-mode ?
posted

Can you tell me what I'm doing wrong ?

Why does the cell not enter edit mode with this ... the correct line is selected and everything,
but I have to use the mouse to click the cell to enter it's edit mode
-> I want the cell in edit-mode right away ...

This is my code: 

_ugFinishDateChanges.DataSource = changes;

 

 

 

if (changes.Count > 0)
{
        _ugFinishDateChanges.Selected.Rows.Clear();
        _ugFinishDateChanges.Selected.Rows.Add(_ugFinishDateChanges.Rows[0]);
        _ugFinishDateChanges.Focus();
        _ugFinishDateChanges.ActiveRow = _ugFinishDateChanges.Rows[0];
        _ugFinishDateChanges.PerformAction(
UltraGridAction.EnterEditMode);

         _ugFinishDateChanges.ActiveCell = _ugFinishDateChanges.Rows[0].Cells[

"ReasonForChange"];  

//why does the actual "ReasonForChange" CELL not get the focus ??

  }

 

 

Parents
  • 469350
    Suggested Answer
    Offline posted

    The code you have here is setting the ActiveCell, but that doesn't put the cell into edit mode. Active and in edit mode are two totally different things.

    What you need to do is, after you set the ActiveCell, call the PerformAction method on the grid and tell it to EnterEditMode.

Reply Children