Categories | Question details Back To List | ||
filterBy trigger onFilterEnd? I noticed that grid.filterBy does not trigger grid.attachEvent("onFilterEnd",function). Is there an event that gets triggered before/after filterBy? I need events to happen after custom filtering. Answer posted by dhxSupport on Jun 22, 2009 05:33 filterBy() method doesn't fire any events as expected that you know when method will be called and you can place any method after filterBy(). If you nedd customize filtering using filterBy() you can use 2nd method's parameter as custom function: mygrid.filterBy(INDEX,doFilterBy); function doFilterBy(value){ //value - cell's value //INDEX - index of a column return data.toString().indexOf("alf")!=-1;// true - show the related row , false - hide the related row } Please see more information here http://dhtmlx.com/docs/products/dhtmlxGrid/doc/articles/Data_filtering_search.html#grid_fsing BTW you can call any available events manually using callEvent() method: mygrid.callEvent("onFilterStart",[]); |