so... I'm new to VBA.
maxnum = Sheets("Cl1").Range("A7").Value
Dim i As Integer
For i = 1 To maxnum
If Sheets("Cl1").Cells(i, 1) = "0" Then
Cells(i, 4).Value = ("TextBox" & i).Value
End If
Next
What I'm trying to do is to push all textboxes values from my UserForm to the sheet in respective order, but ("TextBox" & i).Value is not working - there are 71 textboxes in the UserForm. I need to make it work with For Loop, I know there are many other ways (with .Find, for example). What should I do?
Thanks a lot
Aucun commentaire:
Enregistrer un commentaire