EditFlexGrid
This code allows users to edit in a MSFlexGrid
AI
Resumen de IA: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.
Código fuente
Private Sub MyFlexGrid_KeyPress(KeyAscii As Integer)
'Provides manual data entry capability to flexgrid
With MyFlexGrid
Select Case KeyAscii
Case vbKeyReturn
If .Col + 1 <= .Cols - 1 Then
.Col = .Cols - 1
ElseIf .Row + 1 <= .Rows - 1 Then
.Row = .Row + 1
.Col = 0
Else
.Row = 1
.Col = 0
End If
Case vbKeyBack
If Trim(.Text) <> "" Then
.Text = Mid(.Text, 1, Len(.Text) - 1)
End If
Case Is < 32
Case Else
If .Col = 0 Or .Row = 0 Then
Exit Sub
Else
.Text = .Text & Chr(KeyAscii)
End If
End Select
End With
End Sub
Comentarios originales (3)
Recuperado de Wayback Machine