I have a been using this code below to auto sort my table whenever a change is made to column A89-A144. It works great but it only works for one table and I have 4 separate tables in different rows. Is there a way to get auto sort to do the same this for all 4 tables on my worksheet? Thank you!
Private Sub Worksheet_Change(ByVal Target As Range)
On Error Resume Next
If Not Intersect(Target, Range("A89:A144")) Is Nothing Then
Range("D89").Sort Key1:=Range("D90"), _
Order1:=xlAscending, Header:=xlYes, _
OrderCustom:=1, MatchCase:=False, _
Orientation:=xlTopToBottom
End If
End Sub
Private Sub Worksheet_Change(ByVal Target As Range)
On Error Resume Next
If Not Intersect(Target, Range("A89:A144")) Is Nothing Then
Range("D89").Sort Key1:=Range("D90"), _
Order1:=xlAscending, Header:=xlYes, _
OrderCustom:=1, MatchCase:=False, _
Orientation:=xlTopToBottom
End If
End Sub