Arthur EXL
XLDnaute Nouveau
Bonjour,
Je souhaiterai adapter le code suivant afin que je puisse exclure des textbox, exclure j'entend par là que je voudrais pouvoir saisir du texte dans le texbox "TextObservation" uniquement (celui qui est en commentaire).
	
	
	
	
	
		
Merci par avance pour vos piste,
Cdlt;
	
		
			
		
		
	
				
			Je souhaiterai adapter le code suivant afin que je puisse exclure des textbox, exclure j'entend par là que je voudrais pouvoir saisir du texte dans le texbox "TextObservation" uniquement (celui qui est en commentaire).
		VB:
	
	
	Private Sub VALITATION_Click()
'Gérer les copier/coller TextBox vers Cellules "Données"
Dim OK As Boolean, TB As Variant, LR&
OK = True
For Each TB In Me.Controls
    If TypeOf TB Is MSForms.TextBox And Not IsNumeric(TB) Then
        OK = False
        TB.Value = ""
    End If
Next TB
If OK = False Then
    MsgBox "Merci de renseigner des valeurs numériques dans les champs vides", vbCritical
    Else
    With Worksheets("Données")
        LR = .Cells(.Rows.Count, 3).End(xlUp).Row + 1
        .Cells(LR, 3) = Now
        .Cells(LR, 4) = TextJableMax01 * 1
        .Cells(LR, 5) = TextJableMoy01 * 1
        .Cells(LR, 6) = TextJableMin01 * 1
        .Cells(LR, 7) = TextTLMax01 * 1
        .Cells(LR, 8) = TextTLMoy01 * 1
        .Cells(LR, 9) = TextTLMin01 * 1
        .Cells(LR, 10) = TextEpauleMax01 * 1
        .Cells(LR, 11) = TextEpauleMoy01 * 1
        .Cells(LR, 12) = TextEpauleMin01 * 1
        .Cells(LR, 13) = TextJableMax02 * 1
        .Cells(LR, 14) = TextJableMoy02 * 1
        .Cells(LR, 15) = TextJableMin02 * 1
        .Cells(LR, 16) = TextTLMax02 * 1
        .Cells(LR, 17) = TextTLMoy02 * 1
        .Cells(LR, 18) = TextTLMin02 * 1
        .Cells(LR, 19) = TextEpauleMax02 * 1
        .Cells(LR, 20) = TextEpauleMoy02 * 1
        .Cells(LR, 21) = TextEpauleMin02 * 1
        .Cells(LR, 22) = Now
        .Cells(LR, 23) = (TextJableMoy01 * 1 + TextJableMoy02 * 1) / 2
        .Cells(LR, 24) = (TextTLMoy01 * 1 + TextTLMoy02 * 1) / 2
        .Cells(LR, 25) = (TextEpauleMoy01 * 1 + TextEpauleMoy02 * 1) / 2
        .Cells(LR, 26) = TextMini * 1
        .Cells(LR, 27) = TextMaxi * 1
        '.Cells(LR, 28) = TextObservations * 1   
    End With
    MsgBox "Export terminé", vbInformation
    efface
End If
End Sub
	Merci par avance pour vos piste,
Cdlt;