Dim i As Byte
If Not Len(TextBox1) = 12 Then GoTo pasbon
For i = 1 To 12
Select Case i
Case 1, 4 To 8
If IsNumeric(Mid(TextBox1, i, 1)) Then cpt = cpt + 1
Case 2, 3, 9 To 12
If Mid(TextBox1, i, 1) Like '[A-Z]' Then cpt = cpt + 1
End Select
Next i
If Not cpt = 12 Then GoTo pasbon
Exit Sub
pasbon:
MsgBox 'Merci de respecter la syntaxe'
With TextBox1
.SetFocus
.SelStart = 0
.SelLength = Len(Me.TextBox1)
End With