We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Change "(All)" string to other text on filter bar

Thread ID:

Created:

Updated:

Platform:

Replies:

131653 Jul 21,2017 05:18 AM Jul 24,2017 07:18 AM Windows Forms 1
loading
Tags: GridGroupingControl
Le Lan
Asked On July 21, 2017 05:18 AM

Hi,

Can I change "(All)" to other text on filter bar of GridGroupingControl?

Thanks.

Arulpriya Ramalingam [Syncfusion]
Replied On July 24, 2017 07:18 AM

Hi Le,  
  
Thanks for using Syncfusion products.  
  
Yes, the “(All)” text can be modified in filter dropdown by using the CustomFilterBarCelModel and using SelectAllText property. Please make use of below code and sample,  
  

#region CustomFilterBarCellModel  
public class CustomFilterBarCelModel : GridTableFilterBarCellModel  
{  
    public CustomFilterBarCelModel(GridModel grid)  
        : base(grid)  
    {  
        //To change the "All" text  
        this.SelectAllText = "Sample";  
        //this.SelectCustomText = "Custom text";  
        //this.SelectEmptyText = "Some Text";  
    }  
}  
#endregion  
  
//Registering and adding cell model to Grid  
this.gridGroupingControl1.TableModel.CellModels["CustomFilterBarCell"] =newCustomFilterBarCelModel(this.gridGroupingControl1.TableModel.Model);  
this.gridGroupingControl1.TableDescriptor.Appearance.FilterBarCell.CellType = "CustomFilterBarCell";  
  
  
Screenshot  
  
   
  
Sample link: CustomFilterText   
  
Regards,  
Arulpriya  


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;