cancel
Showing results for 
Search instead for 
Did you mean: 

AddRow with B1 sdk does not move cursor to next row and first column

0 Kudos

Hello all,

I have this code that I use once a user click on the last column, a new row is added. The new row adds but the problem is that the cursor does not go to the new row, it stays on the old row. How can I fix this?

#region Add Row
if (pVal.CharPressed == 9 && (pVal.ColUID == "iV_7" || pVal.ColUID == "sV_4") && pVal.Before_Action == false)
{
_form.Freeze(true);
if (_cmbType.Selected.Value == "Item")
{
ClearItemMatrix();
oIMatrix.AddRow();
GenerateIMatrixNo();
}
if (_cmbType.Selected.Value == "Service")
{
ClearServiceMatrix();
oSMatrix.AddRow();
GenerateSMatrixNo();
}
_form.Freeze(false);
}

Accepted Solutions (1)

Accepted Solutions (1)

former_member233854
Active Contributor

This is normal behavior, in this case try to click in the last cell

YOURMATRIX.Columns.Item(0).Cells.Item(YOURMATRIX.VisualRowCount).Click();

Answers (1)

Answers (1)

0 Kudos

Thanks Danilo. Works!