I have the following code but when I run it I get an error that says, "Run-time error '1004': Application-defined or object-defined error.
Private Sub CommandButton1_Click() erow = Sheets("sheet1").Range("a" & Rows.Count).End(x1Up).Row Range("a" & erow + 1) = TextBox1.Value Range("b" & erow + 1) = TextBox2.Value Range("c" & erow + 1) = TextBox3.Value Range("d" & erow + 1) = TextBox4.Value Range("e" & erow + 1) = TextBox5.Value TextBox1.Value = "" TextBox2.Value = "" TextBox3.Value = "" TextBox4.Value = "" TextBox5.Value = "" End Sub
Please help, thank you.