I am new at this but I feel that I have exhausted mysearch resources for my specific issue. I currently have a workbook with 5sheets. Sheets 1-4 have the exact same template but data within them maychange. Sheet 5 records specific data within each sheet with the click of amacro button into an organized fashion in rows. The VBA code I have works perfectlyfor the initial data, however I will be systematically moving from sheet 1-4and then over again and need previous data to remain unchanged (I.e. Sheet 1 willbe recorded on line 1, 5, 9, sheet 2 recorded on line 2, 6, 10, etc.). How do Iaccomplish this with the click of the same button? Here is the code I currentlyhave:
Sub CopyDataToDZLOG()
Dim NewRow: NewRow = GetNextEmptyRowOnDZLOG
Worksheets("DZ LOG").Cells(NewRow, 2).Value = Worksheets("CHALK 1").Range("C18").Value
Worksheets("DZ LOG").Cells(NewRow, 5).Value = Worksheets("CHALK 1").Range("E7").Value
Worksheets("DZ LOG").Cells(NewRow, 6).Value = Worksheets("CHALK 1").Range("E4").Value
End Sub
Function GetNextEmptyRowOnDZLOG() As Integer
Dim RowCount: RowCount = 6
Do
RowCount = RowCount + 1
Loop Until IsEmpty(Worksheets("DZ LOG").Cells(RowCount, 20).Value)
GetNextEmptyRowOnDZLOG = RowCount
End Function
Please help. Thanks.