Please can someone assist. I have this macro which needs to perform 2 tasks. Hide certain columns, and then filter a column. The button needs to work both ways -Click to activate hide and filter, and click again to unfiltered and unhide.
I have gotten the hide, unhide part working, but I can't figure out how to include removing the filter.
Sub Custom()'
' Custom Macro
With Sheets("Labour Master")
With .Range("h:xx").EntireColumn
.Hidden = Not .Hidden
ActiveSheet.ListObjects("Table1").Range.AutoFilter Field:=5, Criteria1:= _
"<>"
End With
End With
End Sub
Thanks
I have gotten the hide, unhide part working, but I can't figure out how to include removing the filter.
Sub Custom()'
' Custom Macro
With Sheets("Labour Master")
With .Range("h:xx").EntireColumn
.Hidden = Not .Hidden
ActiveSheet.ListObjects("Table1").Range.AutoFilter Field:=5, Criteria1:= _
"<>"
End With
End With
End Sub
Thanks