'How to use dateTimePicker for custom tanslated UI in c# windows form?
When we put a dateTimePicker in windows form, its UI follows "Windows (Operation System) Region". for example if "Region" set to English, the result is English UI, if it set to French, the result is French translated UI, if it set to Russian, the result is Russian translated UI, and so on. But there is no property or any code to change it for custom culture in C#. I search about this issue and some people had suggested this code:
System.Threading.Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo("fr-FR");
or this:
CultureInfo culture = CultureInfo.CreateSpecificCulture("fr-FR");
Thread.CurrentThread.CurrentCulture = culture;
Thread.CurrentThread.CurrentUICulture = culture;
But none of them could change the dateTimePicker UI translation and when "Windows Region" changed, dateTimePicker UI was also changed.
My question is any one know how we can change dateTimePicker UI independent of "Windows Region" changes?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
