中英文系统中,在新窗口中打开文件的问题
使用ShellExecuteEx 打开html文件,在中英文版本的系统中有些不同,请感兴趣的朋友讨论下下,我测试的系统是win2k.
测试如下, 打开一个网页,比如x.html, 然后运行ShellExecuteEx打开c;\\a.html, 现象如下
win2k en: a.html覆盖x.html, 返回的execInfo.hProcess为ox00000000
win2k cn: a.html在新窗口中打开, 返回正确的hProcess
在英文系统环境下,有什么方法可以在新窗口中打开html文件呢? 希望知道的朋友指点一二
我的代码:
SHELLEXECUTEINFO execInfo =
{
sizeof(SHELLEXECUTEINFO),
SEE_MASK_NOCLOSEPROCESS|SEE_MASK_FLAG_DDEWAIT|SEE_MASK_NO_CONSOLE,
NULL,
"open",
"c:\\a.html",
NULL,
"C:\\",
SW_HIDE,//SW_SHOW,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL,
NULL
};
BOOL bRet = ShellExecuteEx( &execInfo );