c# - Has the value of DateTimeFormatInfo::AbbreviatedDayNames ever changed across .Net framework versions for Spain? -
i have following code:
var thursday = new cultureinfo("es-es").datetimeformat.abbreviateddaynames[4];
which returns "ju.", expected.
i have inherited pretty old code, has test code expects value "jue"...
i wondering - has ever changed in .net framework?
edit 1 - extend:
i using .net 4.5... have built machine visual studio 2013 , nothing out of ordinary installed.
var format = new cultureinfo("es-es").datetimeformat; console.writeline("abbreviateddaynames:"); foreach (var name in format.abbreviateddaynames) { console.writeline(name); } console.writeline("shortestdaynames:"); foreach (var name in format.shortestdaynames) { console.writeline(name); }
outputs:
abbreviateddaynames: do. lu. ma. mi. ju. vi. sá. shortestdaynames: d l m x j v s
edit 2 - machine uk english, although don't see why matter if specify culture "es-es"?
edit 3 - weirdly:
https://dotnetfiddle.net/ - returns ju.
http://www.compileonline.com/compile_csharp_online.php - returns jue
the calendardata object makes c# c++ transition when fetching calendar data, on way acquiring calendar information os.
os version , settings differences values in array cause of this, not actual .netfx change.
you can reference c# framework code @ http://www.dotnetframework.org/default.aspx/4@0/4@0/devdiv_tfs/dev10/releases/rtmrel/ndp/clr/src/bcl/system/globalization/calendardata@cs/1305376/calendardata@cs , note managed-to-native included method.
Comments
Post a Comment