Hi all,
I have a macro running in which I am using a UserForm with a dropdown list. The list has three options (pulled from sheet called "Daily").
The operator is required to select one from the list and then continue or cancel.
The command button to continue is required to copy the option selected by the operator and copy it to cell "AZ1" on sheet "Daily".
I cannot get the code for the command button to work;
Sub cmdAdd_Click()
Dim LastRow As Object
Set LastRow = Sheet1.Range("AZ1").End(xlUp)
LastRow.Offset(1, 0).Value = TextBox1.Text
End Sub
Any suggestions on the code or otherwise? I'm open to anything at this stage!
Thanks in advance!!
I have a macro running in which I am using a UserForm with a dropdown list. The list has three options (pulled from sheet called "Daily").
The operator is required to select one from the list and then continue or cancel.
The command button to continue is required to copy the option selected by the operator and copy it to cell "AZ1" on sheet "Daily".
I cannot get the code for the command button to work;
Sub cmdAdd_Click()
Dim LastRow As Object
Set LastRow = Sheet1.Range("AZ1").End(xlUp)
LastRow.Offset(1, 0).Value = TextBox1.Text
End Sub
Any suggestions on the code or otherwise? I'm open to anything at this stage!
Thanks in advance!!