我有一个非 unicode 应用程序,它使用 unicode 版本的 ini 读取函数,如 GetPrivateProfileSectionW 和 GetPrivateProfileStringW。当“非 unicode 程序的语言”设置为英语时,该程序运行良好。
当我将此设置更改为中文 (PRC) 时,GetPrivateProfileSectionW 和 GetPrivateProfileStringW 函数返回 null。
我必须保持这个设置为中文,因为当为“非 unicode 程序的语言”选择英文时,CComBSTR.LoadString 没有按预期工作,它将中文字符加载到资源 DLL 中作为问号。
有任何想法吗?
谢谢。