惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Vercel News
Vercel News
N
Netflix TechBlog - Medium
C
Check Point Blog
MyScale Blog
MyScale Blog
The GitHub Blog
The GitHub Blog
Blog — PlanetScale
Blog — PlanetScale
B
Blog RSS Feed
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
WordPress大学
WordPress大学
博客园 - Franky
MongoDB | Blog
MongoDB | Blog
I
InfoQ
Hugging Face - Blog
Hugging Face - Blog
Recent Announcements
Recent Announcements
人人都是产品经理
人人都是产品经理
腾讯CDC
V
Visual Studio Blog
Engineering at Meta
Engineering at Meta
T
The Blog of Author Tim Ferriss
V
V2EX
云风的 BLOG
云风的 BLOG
Microsoft Azure Blog
Microsoft Azure Blog
U
Unit 42
B
Blog

博客园 - Clingingboy

冒个泡,刷刷存在感 使用文件映射和信号量来进程间通信 Xperf Basics: Recording a Trace (the easy way)(转) Xperf Basics: Recording a Trace(转) Xperf Analysis Basics(转) Android相关sdk使用 Uniscribe文字自动换行 Chrome RenderText分析(2) c++智能指针 GUI 快捷键的实现思路 Menu实现逻辑 控件保持多种绘图状态的做法 2个函数宏技巧 绘图 Painter转接口封装的方式 DirectUI消息循环的简单封装 c++以代理的方式来实现接口化编程 c++对象工厂 使用模板来解决接口继承问题 VC++ 使用attributes定义接口
codepage IMLangCodePages
Clingingboy · 2013-12-02 · via 博客园 - Clingingboy

2013-12-02 14:47  Clingingboy  阅读(503)  评论()    收藏  举报

http://baike.baidu.com/link?url=78DSTGAri8dvHNLQ03rThSKieJqhFwFWL4sQMao6cfaRSOUWN88QVBwmSJPCZch0vfyChnSoRHC1iscdGiSHOK

使用COM对象查询

CoCreateInstance(CLISD_MLANG,NULL,CLSCTX_INPROC_SERVER,__uuidof(IMultiLanguage),(void**)&m_pLanguage);

CComQIPtr<IMLangCodePages> pPages = m_pLanguage;

DWORD* pdwCodePages=0;

pPages ->GetCharCodePages(wCh,pdwCodePages);

pPages->CodePagesToCodePage(*pdwCodePages,1252,pdwCodePage);
if (*pdwCodePage == 1252)
{
    return S_OK;
}
pPages->CodePagesToCodePage(*pdwCodePages,936,pdwCodePage);
if (*pdwCodePage == 936)
{
    return S_OK;
}