Evening All,
Hope someone can help me with the code below.
I am trying to change the code below so that it has the following rules :- if the sheet is empty then update with the new HEADER else if the 1st cell of the sheet is not empty (already contains a header value) then go to the next available blank row, and activate that cell.
Below is my own attempt ( I'm just new to excel VBA) but it doesn't appear to work.....
Any help is much appreciated.
Thanks
Public Sub InOut_Header()
If Parking_Survey.surveySheet.Cells(1, "A") = "" Then
Parking_Survey.surveySheet.Cells(1, "A").Value = "Registration"
Parking_Survey.surveySheet.Cells(1, "B").Value = "Time"
Parking_Survey.surveySheet.Cells(1, "C").Value = "Class"
Parking_Survey.surveySheet.Cells(1, "D").Value = "Type"
Else
Dim Lastrow As Long
Lastrow = Cells(Rows.Count, 1).End(xlUp).Row
End If
End Sub
Bookmarks