相关疑难解决方法(0)

空BSTR和NULL BSTR之间应该有区别吗?

在维护COM接口时应该BSTR像对待空方式一样对待NULL?换句话说,这两个函数调用应该产生相同的结果吗?

 // Empty BSTR
 CComBSTR empty(L""); // Or SysAllocString(L"")
 someObj->Foo(empty);

 // NULL BSTR
 someObj->Foo(NULL);     
Run Code Online (Sandbox Code Playgroud)

string com bstr

9
推荐指数
2
解决办法
7782
查看次数

标签 统计

bstr ×1

com ×1

string ×1