I'm trying to copy cells (strings) from one sheet ('Summary Document' all on row 4) to a table in the second sheet ('Worker 1', starting at B10). I believe I have defined all elements correctly. When I run the first time, it works. however, it gives me a 1004 error on the second run. I'm pretty sure it is my if/then statement that looks for the next empty line, but not sure what the issue is.
Dim FileName As String, FileNumber As String, RecordingPeriod As String, RecordingType As String, Auditor As String, ReviewDate As String`
Dim A1 As String, A2 As String, A3 As String, A4 As String, A5 As String, A6 As String
Worksheets("Summary Document").Select
FileName = Range("C4")
FileNumber = Range("D4")
RecordingPeriod = Range("E4")
RecordingType = Range("F4")
Auditor = Range("G4")
ReviewDate = Range("H4")
A1 = Range("J4")
A2 = Range("K4")
A3 = Range("L4")
A4 = Range("M4")
A5 = Range("N4")
A6 = Range("O4")
Worksheets("Worker 1").Select
Worksheets("Worker 1").Range("B9").Select
If Worksheets("Worker 1").Range("B9").Offset(1, 0) <> "" Then
Worksheets("Worker 1").Range("B9").End(x1Down).Select
End If
ActiveCell.Offset(1, 0).Select
ActiveCell.Value = FileName
ActiveCell.Offset(0, 1).Select
ActiveCell.Value = FileNumber
ActiveCell.Offset(0, 1).Select
ActiveCell.Value = RecordingPeriod
ActiveCell.Offset(0, 1).Select
ActiveCell.Value = RecordingType
ActiveCell.Offset(0, 1).Select
ActiveCell.Value = Auditor
ActiveCell.Offset(0, 1).Select
ActiveCell.Value = ReviewDate
ActiveCell.Offset(0, 2).Select
ActiveCell.Value = A1
ActiveCell.Offset(0, 1).Select
ActiveCell.Value = A2
ActiveCell.Offset(0, 1).Select
ActiveCell.Value = A3
ActiveCell.Offset(0, 1).Select
ActiveCell.Value = A4
ActiveCell.Offset(0, 1).Select
ActiveCell.Value = A5
ActiveCell.Offset(0, 1).Select
ActiveCell.Value = A6
End Sub