I have created a sheet for my team to use when we are sending away damaged items the sheet has an away and returned drop down with away auto sorting to the top, i was looking for a way to make one blank row appear at position 2 (just below the headers) that will still contain all the correct vba in the specific columns and when it is filled in a new one to take its place, any help would be appreciated.
Here is the current macro i made if this will be needed as it has the auto sort feature in it.
Private Sub Worksheet_Change(ByVal Target As Range)
If Cells(Target.Row, "F") > 0 Then
Cells(Target.Row, "A").Select
Else
If Cells(Target.Row, "A") = "Away" Then
Cells(Target.Row, "F") = Now()
End If
End If
If Cells(Target.Row, "G") > 0 Then
Cells(Target.Row, "A").Select
Else
If Cells(Target.Row, "A") = "Returned" Then
Cells(Target.Row, "G") = Now()
End If
End If
If Not (Application.Intersect(Worksheets("WRIST UNITS").Range("A:A"), Target) Is Nothing) Then
DoSort
End If
End Sub
Private Sub DoSort()
Worksheets("WRIST UNITS").Range("A1").CurrentRegion.Sort Key1:=Range("A1"), Order1:=xlAscending, Header:=xlYes
End Sub
Bookmarks