Toggle the filter panel on\off

1
2
3
4
if (Document.ActivePageReference.FilterPanel.Visible == False):
Document.ActivePageReference.FilterPanel.Visible = True
else:
Document.ActivePageReference.FilterPanel.Visible = False