Use LocaleNameToLCID. Be aware that MS is steering away from using LCID. Pity since the locale name is not the same for Windows and Linux.