jump to next control from grid

This commit is contained in:
Jonathan Jenne 2019-10-18 12:28:38 +02:00
parent 8b1f6a70c8
commit 63db534eeb

View File

@ -880,7 +880,26 @@ Public Class frmValidator
Where r.CONTROL_ID = oControlRow.Item("GUID")
Select r).ToList()
oMyControl = ClassControlCreator.CreateExistingGridControl(oControlRow, columns, False)
Dim oGrid = ClassControlCreator.CreateExistingGridControl(oControlRow, columns, False)
AddHandler oGrid.ProcessGridKey, Sub(ByVal _sender As Object, ByVal e As KeyEventArgs)
If e.KeyCode = Keys.Tab Then
Dim gridControl = TryCast(_sender, GridControl)
Dim view = TryCast(gridControl.FocusedView, Views.Base.ColumnView)
If (e.Modifiers = Keys.None And view.IsNewItemRow(view.FocusedRowHandle) And view.FocusedColumn.VisibleIndex = view.VisibleColumns.Count - 1) Then
If view.IsEditing Then
view.CloseEditor()
Me.SelectNextControl(gridControl, e.Modifiers = Keys.None, True, True, True)
e.Handled = True
End If
End If
End If
End Sub
oMyControl = oGrid
Case "LINE"
LOGGER.Debug("Versuch Linie zu laden")