E
Esrei
I am currently busy designing a form to populate a list, and have this macro.
My only porblem is that I do not enter one line at a time I can enter up to
40. The first part of the macro works fine only then I want to take a ragne
form the Form worksheet and place it on the data worksheet.
Thank you for all the help the site has motivated me to buy a book on VB and
start studding, mor I just need a push in the right direction.
Regards
ES
Sub Button2_click()
Dim NewRow As Integer
NewRow = Worksheets("Form").Range("O1").Value + 1
If Worksheets("Form").Range("O2").Value <> 0 Then
MsgBox "There are errors, please enter data into all the fields", vbOKOnly,
"MeadInKent"
Exit Sub
End If
Worksheets("data").Cells(NewRow, 1).Value =
Worksheets("form").Range("A10:A40").Value
Worksheets("form").Range("A1").Select
End Sub
My only porblem is that I do not enter one line at a time I can enter up to
40. The first part of the macro works fine only then I want to take a ragne
form the Form worksheet and place it on the data worksheet.
Thank you for all the help the site has motivated me to buy a book on VB and
start studding, mor I just need a push in the right direction.
Regards
ES
Sub Button2_click()
Dim NewRow As Integer
NewRow = Worksheets("Form").Range("O1").Value + 1
If Worksheets("Form").Range("O2").Value <> 0 Then
MsgBox "There are errors, please enter data into all the fields", vbOKOnly,
"MeadInKent"
Exit Sub
End If
Worksheets("data").Cells(NewRow, 1).Value =
Worksheets("form").Range("A10:A40").Value
Worksheets("form").Range("A1").Select
End Sub