UuidToString在ATL的问题,在线等待
nbt 2003-06-12 09:17:19 我有以下程序在debug时编译是成功,但在unicode release minize时提示错误
BYTE *uuid;
GUID Guid;
CComBSTR bstrTemp;
bstrTemp.AppendBSTR(bstrDirPath);
bstrTemp.Append("\\filepath\\");
CoCreateGuid(&Guid);
UuidToString(&Guid,&uuid);
bstrTemp.Append((LPCSTR)uuid);
bstrTemp.Append(".xml");
RpcStringFree(&uuid);
错误如下:
error C2664: 'UuidToStringW' : cannot convert parameter 2 from 'unsigned char ** ' to 'unsigned short ** '
Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
error C2664: 'RpcStringFreeW' : cannot convert parameter 1 from 'unsigned char ** ' to 'unsigned short ** '
Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast