Hello,
We have an application that is used by clients from different countries in multiple languages. The date and number formats have to be the same for all clients in a certain country, the language can be selected by the user.
This works well by specifying the Thread.CurrentThread.CurrentCulture for the date and number formats and the Thread.CurrentThread.CurrentUICulture for the culture of the user's language.
When formatting dates, the names of the days and months are taken from the CurrentCulture. To make sure these names match the UICulture, we copy the names from the UICulture to the Culture. This works fine in most situations (for example in the DateTime.Format() function).
The behaviour of the RadDatePicker and RadMonthYearPicker seems a bit off though. In the picker (popup) the day and month names are correctly taken from the culture as we set them. In the input field however, the original day and month names are used. This seems wrong to me. Are we doing something wrong, or is this a bug in how the date pickers use the culture settings?
var uiCulture = CultureInfo.CreateSpecificCulture("nl-NL");
var customCulture = CultureInfo.CreateSpecificCulture("en-US");
customCulture.DateTimeFormat.AbbreviatedDayNames = uiCulture.DateTimeFormat.AbbreviatedDayNames;
customCulture.DateTimeFormat.DayNames = uiCulture.DateTimeFormat.DayNames;
customCulture.DateTimeFormat.AbbreviatedMonthGenitiveNames = uiCulture.DateTimeFormat.AbbreviatedMonthNames;
customCulture.DateTimeFormat.AbbreviatedMonthNames = uiCulture.DateTimeFormat.AbbreviatedMonthNames;
customCulture.DateTimeFormat.MonthNames = uiCulture.DateTimeFormat.MonthNames;
customCulture.DateTimeFormat.MonthGenitiveNames = uiCulture.DateTimeFormat.MonthGenitiveNames;
customCulture.DateTimeFormat.ShortestDayNames = uiCulture.DateTimeFormat.ShortestDayNames;
Thread.CurrentThread.CurrentCulture = customCulture;
Thread.CurrentThread.CurrentUICulture = uiCulture;
The day and month names of the picker are localized, the input field is not.
Thanks for any suggestions,
Cloud9Software.
Hi guys,
I'm using 2 MonthYearPickers on a page and need that one of them to show only the year.
How can i do this? Tryed the css solution with #rcMView_month but that changes for both controls.
Thanks,
Antonio
This isn't an actual problem, but more of a curiosity. Why does something called the RadMonthYearPicker still render a full date and time? I thought that's what the RadDatePicker was for? It should just give me the Month and Year and no date...which is what it's name would lead you to believe is all that would be involved. I'm not choosing June 1st 2022. I'm choosing June 2022. I understand that I can format the selected date...that's not the point.
Things that make you go hummmmm.
Hi,
could somebody give me an advice, whether it's possible to have months in the same format as years ? I mean, now there are Jan. , Feb. .. and I want there only month numbers 01, 02.
And my second issue is how to change selected row value. Now, when I choose some month and year and click on OK button, there is January 2020. I need selected date in the format 01/2020, or 02/2020
Please, help me to solve this issues.
Regards
Vasssek
I'm attempting to use the RadMonthYearPicker inside of a RadGrid EditItemTemplate in BatchEdit mode and I'm having an issue getting the picker to accept and exit all forms of it's editors when the user clicks 'OK'
I've attached a screenshot to help illustrate what I mean.
I have a OnBatchEditCellValueChanged function that then validates the date selected and pulls some DB values to other columns.
I have everything working like I want it accept when using the picker you have to manually click off the row before the changed event will fire.
I've tried several different methods of moving the cursor, setting focus, blurs, saving the table via batch manager and I'm sure a few other things and haven't had success yet.
Any direction at this point would be much appreciated.
I would like to use the RadMonthYearPicker Component in an application with Swedish language. I need two Controls for letting the users to define a period. But I have a problem with setting the texts on the Today and Cancel buttons.
I've tried changing the settings in MonthYearNavigationSettings in the Page_Load, but just the first call for each Component makes an impact on the result.
For example:
rmypFromDatum.MonthYearNavigationSettings.CancelButtonCaption = "Avbryt";
rmypFromDatum.MonthYearNavigationSettings.TodayButtonCaption = "Idag";
rmypTomDatum.MonthYearNavigationSettings.TodayButtonCaption = "Idag";
rmypTomDatum.MonthYearNavigationSettings.CancelButtonCaption = "Avbryt";
then in the first Component, rmypFromDatum, the text on the Cancel Button is changed to "Avbryt", but the text on the Today button is English - Today. And vice versa - on the second Component the Today button has the text changed to "Idag" but the Cancel button has the text "Cancel.
When a button is clicked on the page and the page is reloaded both the buttons - Today and Cancel - get the Swedish texts.
What shall I do to make my Changes to be visible the first time the users open the Components. Please help!
Best regards,
Jenny
Hello everyone,
I want to change my date input format in client side using Javascript.
I saw there is a get_dateInput but I don't know how to use it to set the RadMonthYearPicker format to "MMMM".
Do anyone have a simple example?
Thank you in advance.