W
w0rd
Hi guys,
Wondering if you could help me with some errors I've been getting with
the source of a commissioned project. I've got no C++ experience so
I've got no idea what's going on but when I try to compile in debug
mode I get these errors (I've included the lines lines where the
errors happen if it helps):
addrinfo *AI;
\Async.cpp(47) : error C2065: 'addrinfo' : undeclared identifier
\Async.cpp(47) : error C2065: 'AI' : undeclared identifier
\Async.cpp(47) : warning C4552: '*' : operator has no effect; expected
operator with side-effect
if(getaddrinfo(lpszHost, "80", NULL, &AI) != 0)
\Async.cpp(50) : error C2065: 'getaddrinfo' : undeclared identifier
SOCKET s = socket(AI->ai_family, SOCK_STREAM, 0);
\Async.cpp(56) : error C2227: left of '->ai_family' must point to
class/struct/union
if(connect(s, AI->ai_addr, AI->ai_addrlen) == SOCKET_ERROR)
\Async.cpp(63) : error C2227: left of '->ai_addr' must point to class/
struct/union
\Async.cpp(63) : error C2227: left of '->ai_addrlen' must point to
class/struct/union
ULONG (PASCAL *SendMail)(ULONG, ULONG_PTR, MapiMessage*, FLAGS,
ULONG);
\Utils.cpp(257) : error C2143: syntax error : missing ')' before
'__stdcall'
\Utils.cpp(257) : error C2059: syntax error : ')'
(FARPROC&)SendMail = GetProcAddress(hMAPI, _T("MAPISendMail"));
\Utils.cpp(258) : error C2065: 'SendMail' : undeclared identifier
int nError = SendMail(0, (ULONG_PTR)AfxGetMainWnd()->m_hWnd,
&message, MAPI_LOGON_UI|MAPI_DIALOG, 0);
\Utils.cpp(284) : error C2065: 'ULONG_PTR' : undeclared identifier
\Utils.cpp(284) : error C2146: syntax error : missing ')' before
identifier 'AfxGetMainWnd'
\Utils.cpp(284) : error C2059: syntax error : ')'
I've got a feeling some of the errors come from me missing some sort
of global files.
Thanks in advance.
Wondering if you could help me with some errors I've been getting with
the source of a commissioned project. I've got no C++ experience so
I've got no idea what's going on but when I try to compile in debug
mode I get these errors (I've included the lines lines where the
errors happen if it helps):
addrinfo *AI;
\Async.cpp(47) : error C2065: 'addrinfo' : undeclared identifier
\Async.cpp(47) : error C2065: 'AI' : undeclared identifier
\Async.cpp(47) : warning C4552: '*' : operator has no effect; expected
operator with side-effect
if(getaddrinfo(lpszHost, "80", NULL, &AI) != 0)
\Async.cpp(50) : error C2065: 'getaddrinfo' : undeclared identifier
SOCKET s = socket(AI->ai_family, SOCK_STREAM, 0);
\Async.cpp(56) : error C2227: left of '->ai_family' must point to
class/struct/union
if(connect(s, AI->ai_addr, AI->ai_addrlen) == SOCKET_ERROR)
\Async.cpp(63) : error C2227: left of '->ai_addr' must point to class/
struct/union
\Async.cpp(63) : error C2227: left of '->ai_addrlen' must point to
class/struct/union
ULONG (PASCAL *SendMail)(ULONG, ULONG_PTR, MapiMessage*, FLAGS,
ULONG);
\Utils.cpp(257) : error C2143: syntax error : missing ')' before
'__stdcall'
\Utils.cpp(257) : error C2059: syntax error : ')'
(FARPROC&)SendMail = GetProcAddress(hMAPI, _T("MAPISendMail"));
\Utils.cpp(258) : error C2065: 'SendMail' : undeclared identifier
int nError = SendMail(0, (ULONG_PTR)AfxGetMainWnd()->m_hWnd,
&message, MAPI_LOGON_UI|MAPI_DIALOG, 0);
\Utils.cpp(284) : error C2065: 'ULONG_PTR' : undeclared identifier
\Utils.cpp(284) : error C2146: syntax error : missing ')' before
identifier 'AfxGetMainWnd'
\Utils.cpp(284) : error C2059: syntax error : ')'
I've got a feeling some of the errors come from me missing some sort
of global files.
Thanks in advance.