1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
| '--------------------------------------
'dans un module de classe nommé "Classe1"
'
Option Explicit
Public WithEvents TexteGroup As MSForms.TextBox
Private Sub TexteGroup_KeyUp(ByVal KeyCode As _
MSForms.ReturnInteger, ByVal Shift As Integer)
Dim Valeur As Byte
Valeur = TexteGroup.Index
If KeyCode = 9 Then
If Valeur <> Collect.Count Then
With Collect(Valeur + 1).TexteGroup
.Activate
End With
Else
With Collect(1).TexteGroup
.Activate
End With
End If
End If
End Sub
'-------------------------------------- |