DataViewBase.RuntimeLocalizationStrings Property
Gets or sets the collection of resource strings that can be localized at runtime. This is a dependency property.
Namespace: DevExpress.Xpf.Grid
Assembly: DevExpress.Xpf.Grid.v25.2.Core.dll
NuGet Package: DevExpress.Wpf.Grid.Core
Declaration
Property Value
| Type | Description |
|---|---|
| DevExpress.Xpf.Grid.GridRuntimeStringCollection | A DevExpress.Xpf.Grid.GridRuntimeStringCollection object that contains resource strings that can be localized at runtime. |
Remarks
Individual default strings displayed within the grid (e.g. group panel text, the column chooser’s caption, etc.) can be changed at runtime. To translate individual resource strings at runtime, create a DevExpress.Xpf.Grid.RuntimeStringIdInfo object with the specified Id and Value properties, and add it to the View’s RuntimeLocalizationStrings collection. The Id property identifies the required resource string. The Value property specifies a new value for it.
Example
This example shows how to change the default string displayed in the Group Panel at runtime.

<dxg:GridControl x:Name="grid" AutoGenerateColumns="AddNew">
<dxg:GridControl.View>
<dxg:TableView x:Name="view" AutoWidth="True"/>
</dxg:GridControl.View>
</dxg:GridControl>
<StackPanel Grid.Row="1" Orientation="Horizontal">
<TextBox x:Name="textBox" Width="200" KeyDown="textBox_KeyDown" Margin="3,3,3,3"/>
<Button Content="Apply" Click="button_Click" Margin="0,3,0,3"/>
</StackPanel>
void LocalizeGroupPanelText() {
var NewText = textBox.Text;
var localization = new GridRuntimeStringCollection();
localization.Add(new RuntimeStringIdInfo(GridControlRuntimeStringId.GridGroupPanelText, NewText));
view.RuntimeLocalizationStrings = localization;
}
void button_Click(object sender, RoutedEventArgs e) {
LocalizeGroupPanelText();
}
void textBox_KeyDown(object sender, System.Windows.Input.KeyEventArgs e) {
if (e.Key == System.Windows.Input.Key.Enter) {
LocalizeGroupPanelText();
}
}