I am pretty new to VBA, I have a userform created and all I want it to do is after the enter button is clicked, it adds the filled-in text boxes onto the next empty row in the excel sheet. I get object variable not set (on the rw = ws.Cells line) and I'm not sure how to set it.
Thanks so much.
Private Sub enter_Click()
Dim rw As Integer
Dim ws As Worksheet
Set ws = Worksheets("Home")
rw = ws.Cells.Find(What:=” * ”, SearchOrder:=xlRows, SearchDirection:=xlPrevious, LookIn:=xlValues).Row + 1
ws.Cells(rw, 1).Value = Me.TextBox1.Value
ws.Cells(rw, 2).Value = Me.TextBox2.Value
End Sub