GridControlLocalizer Class
In This Article
A base class that provides necessary functionality for custom localizers of the Data Grid control.
Namespace: DevExpress.Xpf.Grid
Assembly: DevExpress.Xpf.Grid.v24.2.Core.dll
NuGet Package: DevExpress.Wpf.Grid.Core
#Declaration
#Remarks
Note
Important: Not all strings can be translated via Localizer classes. Some components contain form resources (e.
#Example
This example uses the GridControlLocalizer
to replace the following GridControl‘s strings:
- Customize… → Customize Totals
- Totals for ‘Column Name’ → Totals Editor
- Items → Summary Items
public partial class MainWindow : Window {
public MainWindow() {
// ...
}
static MainWindow() {
GridControlLocalizer.Active = new CustomDXGridLocalizer();
}
}
public class CustomDXGridLocalizer : GridControlLocalizer {
protected override void PopulateStringTable() {
base.PopulateStringTable();
// Changes the caption of the menu item used to invoke the Total Summary Editor.
AddString(GridControlStringId.MenuFooterCustomize, "Customize Totals");
// Changes the Total Summary Editor's default caption.
AddString(GridControlStringId.TotalSummaryEditorFormCaption, "Totals Editor");
// Changes the default caption of the tab page that lists total summary items.
AddString(GridControlStringId.SummaryEditorFormItemsTabCaption, "Summary Items");
}
}
#Inheritance
See Also