If you want display of archived records to be optional then:1) make the archive flag a tinyint with a default value of 0 (which you will set to 1 for archived records)
2) in PHPM, define the field as a checkbox, and include it as an Ext. Search item on the list page
3) in the Recordset_Selecting event, put this to include archived records in the list of active records:$filter = "Archived <= " . Post(“x_Archived”, 0);…or this to show only archived records:$filter = "Archived = " . Post(“x_Archived”, 0);The idea is that if the search checkbox is left blank then you get the active records only, but if it’s checked then you add in or show only archived records.