9

Is it possible to determine if the CultureInfo instance that I am working with is based on a Latin character set or not?

user7116
  • 63,008
  • 17
  • 141
  • 172
januszstabik
  • 1,152
  • 5
  • 16
  • 30

2 Answers2

3

I believe you can use the CultureInfo.TextInfo.ANSICodePage. There are only so many of these (detailed here: http://msdn.microsoft.com/en-us/goglobal/bb964654).

You mostly just need to check that it's value is either 1252 or 1250

ewino
  • 185
  • 1
  • 9
1

Not sure whether this is sufficient, but how about testing the CultureInfo.NativeName property for Latin characters using the CharUnicodeInfo.GetUnicodeCategory method

See also the Unicode UAX #24 on Script Properties and the Unicode Character to Script assignment table.

devio
  • 36,858
  • 7
  • 80
  • 143