If Target.Count > 1 Then Exit Sub
If Not Intersect(Target, [D1:D2]) Is Nothing Then
If LCase([D1]) = "x" Then
[G:H].EntireColumn.Hidden = False
[H:H].EntireColumn.Hidden = True
On Error Resume Next
ActiveSheet.ShowAllData
Range("$G$4:$G$" & Range("G65500").End(xlUp).Row).AutoFilter Field:=1, Criteria1:="<>"
End If
If LCase([D2]) = "x" Then
[G:H].EntireColumn.Hidden = False
[G:G].EntireColumn.Hidden = True
On Error Resume Next
ActiveSheet.ShowAllData
Range("$H$4:$H$" & Range("H65500").End(xlUp).Row).AutoFilter Field:=1, Criteria1:="<>"
End If
If LCase([D1]) <> "x" And LCase([D2]) <> "x" Then
[G:H].EntireColumn.Hidden = False
On Error Resume Next
ActiveSheet.ShowAllData
End If
End If
End Sub