1 Reply Latest reply on Jan 27, 2008 7:57 PM by atta707

    Filter with checkbox

    Sandlot07
      I am attempting to build a filter that will add or remove items from a Datagrid. The two fields I would like to filter are categories and locations. I would like to filter the two fields with a checkbox for each field. Here is the example. A user selects a location which filters the categories available at that location, it also filters the Datagrid. The user then selects a category which filters the DataGrid. If the user removes the check mark, the filtered data is removed from the DataGrid. The filter also has the ability to display all items.
        • 1. Re: Filter with checkbox
          atta707 Level 2
          1) all the checkboxe's click event can point to same event listener
          2) event.currentTarget would tell you what checkbox has been clicked on
          3) you'd need to maintain a list of all the checked boxes
          4) implement a filter function based on the list and set it to the filterFunction property of the ArrayColleciton that you're using to populate the datagrid

          Hope this helps.

          ATTA