我的程序在Win32 Release MinSize下能编译通过但在Win32 Unicode Release MinSize下不能通过?经测试在所有Unicode情况下都不能通过程序如下:
.....
pServer = session.GetHttpConnection(bsURL,0,80,lpUserName,lpPassword);
pFile = pServer->OpenRequest(3,lpDesfile,NULL,0,NULL,_T("HTTP/1.0"));//在此出错
pFile->SendRequest(NULL,0,pbuf,lLen);
......error C2664: 'class CHttpFile *__thiscall CHttpConnection::OpenRequest(const unsigned short *,const unsigned short *,const unsigned short *,unsigned long,const unsigned short ** ,const unsigned
short *,unsigned long)' : cannot convert parameter 1 from 'const int' to 'const unsigned short *'
Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
经过查找帮助CHttpConnection::OpenRequest方法有两种不同形式,但这里为什么只认可第一种?
.....
pServer = session.GetHttpConnection(bsURL,0,80,lpUserName,lpPassword);
pFile = pServer->OpenRequest(3,lpDesfile,NULL,0,NULL,_T("HTTP/1.0"));//在此出错
pFile->SendRequest(NULL,0,pbuf,lLen);
......error C2664: 'class CHttpFile *__thiscall CHttpConnection::OpenRequest(const unsigned short *,const unsigned short *,const unsigned short *,unsigned long,const unsigned short ** ,const unsigned
short *,unsigned long)' : cannot convert parameter 1 from 'const int' to 'const unsigned short *'
Conversion from integral type to pointer type requires reinterpret_cast, C-style cast or function-style cast
经过查找帮助CHttpConnection::OpenRequest方法有两种不同形式,但这里为什么只认可第一种?
such as MultiByteToWideChar (CP_ACP, 0, lpBufferA, -1, lpBufferW, dwSize);
_________
lpDesfile
是什么类型?
把3换成_T(PUT)