How to check, from C#, are files for complex script and rtl languages installed?

前端 未结 2 503
爱一瞬间的悲伤
爱一瞬间的悲伤 2021-01-16 17:51

How to check, from C#, are files for complex script and rtl languages (Regional and Language settings) installed?

Edit: Or is there another way of checking whether r

2条回答
  •  北恋
    北恋 (楼主)
    2021-01-16 18:46

    Thank you for your info. I queried WMI for Win32_OperatingSystem Properties. It returns Win32_OperatingSystem Class with all fields and properties except MUILanguages :(

    ...
      uint32 MaxNumberOfProcesses;
      uint64 MaxProcessMemorySize;
      string MUILanguages[]; //I don't see this field, and all others I see
      string Name;
      uint32 NumberOfLicensedUsers;
    ...
    

    Any help? I use WinXP SP2 and VS2005

    Code I used refereence: System.Management;

    string ConfigNamespace = @"\\.\root\cimv2";
    string query = "select * from Win32_OperatingSystem";
    
    ManagementObjectSearcher searcher = 
      new ManagementObjectSearcher(ConfigNamespace, query);
    
    ManagementObjectCollection collection = searcher.Get();
    
    foreach (ManagementObject item in collection)
    {
      //PropertyData pd = item.Properties["MUILanguages"];
    
      foreach (PropertyData data in item.Properties)
      {
    
      }
    }
    

提交回复
热议问题