Search code examples
visual-c++windows-8.net-4.5globalization

Missing Globalization Support in Windows 8 C++ Apps


I'm looking to take advantage of a number of globalization techniques within my Visual-C++ (C++/Cx) app for the Windows 8 store. More specifically, I thought I'd start with language-sensitive sorting. Within the documentation, it alludes to a set of APIs that help sort strings but it doesn't list which ones. Digging deeper, I found System.Globalization.CompareInfo for C# that does exactly what I want, but it doesn't seem to be available for C++. Does this support just plain not exist for C++ apps?

Perhaps the greater question here is this - is there a reliable set of docs that tell me the differences between Win 8 C# app APIs vs C++ app APIs?


Solution

  • You can find a fair amount of Globalization support in the Windows.Globalization namespace. This functionality is available to all the WinRT projection languages. Unfortunately there is no collation support in there except for character groupings. You can use the Win32 NLS apis (CompareStringEx)