New to Telerik UI for WPF? Download free 30-day trial

Change Localization of the FindDialog of PdfViewer During Runtime

Environment

Product Version 2023.2.718
Product RadPdfViewer for WPF

Description

How to change the culture of the find dialog of RadPdfViewer at runtime, thus changing the language.

Solution

To change the localization settings of the find dialog, you will need to unregiser it in order to unload it. Then set the application culture and, register the dialog again.

private void Button_Click(object sender, RoutedEventArgs e) 
{ 
        RadPdfViewerAttachedComponents.SetRegisterFindDialog(pdfViewer, false); 
        Thread.CurrentThread.CurrentCulture = new CultureInfo("de"); 
        Thread.CurrentThread.CurrentUICulture = new CultureInfo("de"); 
        RadPdfViewerAttachedComponents.SetRegisterFindDialog(pdfViewer, true); 
} 
In this article