Search code examples
gwtsearchsmartgwttreegrid

Is it possible to implement the search functionality in a TreeGrid in smartGWT?


Is it possible to replicate the search functionality found in ListGrid and implement it for a TreeGrid to find all the tree nodes which matches the search criteria?

Here is the one for the ListGrid:

http://www.smartclient.com/smartgwt/showcase/#grid_adaptive_filter_featured_category


Solution

  • TreeGrid extends ListGrid. So whatever functionalities you're getting with ListGrid, are also available with TreeGrid. You can definitely have searching functionality in TreeGrid by these properties:

    myTreeGrid.setShowFilterEditor(true);
    myTreeGrid.setFilterOnKeypress(true);
    

    But these functionalities will work only if you're using DataSource for generating the TreeGrid as per my knowledge.

    Hope this information helps you.