SchedulerControlLocalizer Class
A base class that provides necessary functionality for custom localizers of the SchedulerControl.
Namespace: DevExpress.Xpf.Scheduler
Assembly: DevExpress.Xpf.Scheduler.v22.2.dll
NuGet Package: DevExpress.Wpf.Scheduler
Declaration
Remarks
Important
You are viewing documentation for the legacy WPF Scheduler control. If you’re starting a new project, we strongly recommend that you use a new control declared in the DevExpress.Xpf.Scheduling namespace. If you decide to upgrade an existing project in order to switch to the updated scheduler control, see the Migration Guidelines document.
Note
Important: Not all strings can be translated via Localizer classes. Some components contain form resources (e.g., the XtraReports Search dialog), and the only way to translate them is to create satellite assemblies. Thus, localization via resources is the preferable solution.
For more information on utilizing the SchedulerControlLocalizer class, refer to the Localizing WPF Controls via Localizer Objects document.
Example
Shared Sub New()
SchedulerControlLocalizer.Active = New CustomSchedulerLocalizer()
End Sub
Private Class CustomSchedulerLocalizer
Inherits SchedulerControlLocalizer
' Modify the specified caption.
Public Overrides Function GetLocalizedString(ByVal id As DevExpress.Xpf.Scheduler.SchedulerControlStringId) As String
If id = SchedulerControlStringId.ButtonCaption_DismissAll Then
Return "42"
Else
Return MyBase.GetLocalizedString(id)
End If
End Function
' Localize UI strings.
' Note that not all strings can be translated with Localizer classes. Use satellite assemblies in this situation.
Protected Overrides Sub PopulateStringTable()
'base.PopulateStringTable();
For Each s As SchedulerControlStringId In System.Enum.GetValues(GetType(SchedulerControlStringId))
AddString(s, System.Enum.GetName(GetType(SchedulerControlStringId), s))
Next s
End Sub
End Class