I am trying to get data from a user form to my excel sheet. I have done this before but not as complex.
Team owner is TextBox1 and the players values are Textbox 2 - 9
I would like to do multiple entries. So each time I submit, a new team owner in row a and the players listed below it in row b
Any tips would be greatly appreciated.
Thank you
Team owner is TextBox1 and the players values are Textbox 2 - 9
I would like to do multiple entries. So each time I submit, a new team owner in row a and the players listed below it in row b
Code:
Private Sub CommandButton1_Click()
Dim lrow, currentrow, x As Integer
lrow = Cells(Rows.Count, 1).End(xlUp).Row
currentrow = lrow + 1
Cells(currentrow, 1).Value = "Owner"
Cells(currentrow, 2).Value = "Team"
For x = 2 To 9
Cells(currentrow + x, 2).Value = TextBox(x).Value
Next i
End Sub
Any tips would be greatly appreciated.
Thank you