Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
Developer Community or GitHub with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
Created attachment 820 [details]
DateTime.ToShortTimeString() in Greece Region Format
When I call the DateTime.ToShortTimeString() and the selected device region format is "Greece", the function does not return a properly foramated time.
It returns "2:23 M", however this time format does not exist in Greece.
The correct format is "2:23 μ.μ" like in the device status bar.
See the attached image.
this looks like a duplicate of bug #533 - can you try the workaround (i.e. using the pattern) and tell us if this works for you ? thanks
I do not want to hardcode the datetime pattern because this will result in wrong formated dates and times under differents culture and user settings.
I tried the "hh:mm tt" format and it does not display the time correctly.
The output is "2:15 MM"
It should be: "2:15 μ.μ."
Also the user migth have the 24 hour format selected in his device. Thats why the ToShortTimeString method is required, so that the programmer will not have to deal with all these date and time formats and user settings under all these locales.
One more thing to add is that the build in ShortTimePattern returns "h:mm t" which is not correct for Greece locale. It should be "h:mm tt"
I see that this bug has a NEEDINFO status.
Do you need some more info to resolve this issue? Can I help somehow?
This has been fixed in mono master / 2.11.
The change is a major one, so it will only reach the mobile platforms (mono for android / monotouch) when those products are rebased on the upcoming mono 2.12 release instead of the currently stable 2.10 release. This will happen some time later this year, but a date has not been set yet.
*** This bug has been marked as a duplicate of bug 4782 ***