stepsbysteps
XLDnaute Nouveau
Bonjour j'aimerai savoir comment serait ce possible d'afficher une ligne dans un userform par exemple un textbox.
j'ai essayé cela mais ca ne marche pas
où ma fonction ligne_match est :
il selectionne la bonne ligne mais je suis coincé pour l'afficher dans un userform ou autre
merci d'avance
j'ai essayé cela mais ca ne marche pas
Code:
Private Sub CommandButton2_Click()
Sheets(2).Activate
l = ligne_match(TextBox1)
ligne1 = Range("A" & l).Row
Rows(ligne1).Select
TextBox6.Value = Row(ligne1).Value
End Sub
où ma fonction ligne_match est :
Code:
Function ligne_match(ByVal critere As Long)
i = 2
Do While (Not Sheets(2).Cells(i, 1) = critere)
i = i + 1
Loop
ligne_match = i
End Function
il selectionne la bonne ligne mais je suis coincé pour l'afficher dans un userform ou autre
merci d'avance