@@error C2679问题。。。
error C2679: binary '=' : no operator defined which takes a right-hand operand of type 'const int' (or there is no acceptable conversion)
STDMETHODIMP CNiceCLSAPI::CapiGetConStatus(VARIANT *isConnect, long *nRetCode)
{
MyBOOL isConnected = FALSE;
MyBOOL isEvConnected = FALSE;
try
{
*nRetCode = clsConnectionStatus ( &isConnected, &isEvConnected );
if( *nRetCode == CLS_RC_SUCCESS )
{
*isConnect = isConnected;//此行出错
}
return S_OK;
}
catch(...)
{
*nRetCode = CLS_RC_GENERAL_FAILURE;
return S_FALSE;
}
}