Patriot2879
Well-known Member
- Joined
- Feb 1, 2018
- Messages
- 1,259
- Office Version
- 2010
- Platform
- Windows
Hi really helping you can help me with the code below please, i have a userform which i can fill out, when i click the ok button i want the information entered to be transferred into sheet6 in columns a - d then every time new info is added to goto a new lane, but i keep getting erros pop up please can you help again, i am very new to all this so still learning, and any advise you can give will be very much appreciated
Code:
Private Sub OKButton_Click()
Dim emptyRow As Long
'Make Sheet1 active
Sheet1.Activate
'Determine emptyRow
emptyRow = ThisWorkbook.Sheets("Sheet6").CountA(Range("A:D")) + 1
'Transfer information
Cells(emptyRow, 1).Value = DateBox.Value
Cells(emptyRow, 2).Value = MPANBox.Value
Cells(emptyRow, 3).Value = ManagerBox.Value
Cells(emptyRow, 4).Value = NotesBox.Value
End Sub