NetJoinDomain-lm.h, lmjoin.h
-
Hi all, I want to use NetJoinDomain function. It always ends by errors(89) in Lmjoin.h or Lm.h. I have linked netapi32.dll. Here is one of 89 errors: Error 1 error C2146: syntax error : missing ';' before identifier 'NET_API_FUNCTION' c:\program files\microsoft visual studio 8\vc\platformsdk\include\lmjoin.h 99 What am I doing wrong? Thanks.
-
Hi all, I want to use NetJoinDomain function. It always ends by errors(89) in Lmjoin.h or Lm.h. I have linked netapi32.dll. Here is one of 89 errors: Error 1 error C2146: syntax error : missing ';' before identifier 'NET_API_FUNCTION' c:\program files\microsoft visual studio 8\vc\platformsdk\include\lmjoin.h 99 What am I doing wrong? Thanks.
I think you've just included
Lmjoin.h
. It needsLm.h
also. Just include both as follows.#include "Lm.h"
#include "lmjoin.h"Me too had the same error by just including
Lmjoin.h
. :rolleyes: Regards, Jijo._____________________________________________________ http://weseetips.com[^] Visual C++ tips and tricks. Updated daily.
-
I think you've just included
Lmjoin.h
. It needsLm.h
also. Just include both as follows.#include "Lm.h"
#include "lmjoin.h"Me too had the same error by just including
Lmjoin.h
. :rolleyes: Regards, Jijo._____________________________________________________ http://weseetips.com[^] Visual C++ tips and tricks. Updated daily.
-
Thank for your reply but it's same Error 1 error C2143: syntax error : missing ';' before '__stdcall' c:\program files\microsoft visual studio 8\vc\platformsdk\include\lmaccess.h 46 Regards, Daavena
daavena wrote:
but it's same
Not quite. If you'll notice the errors are different. Error 1 error C2146: syntax error : missing ';' before identifier 'NET_API_FUNCTION' c:\program files\microsoft visual studio 8\vc\platformsdk\include\lmjoin.h 99 Error 1 error C2143: syntax error : missing ';' before '__stdcall' c:\program files\microsoft visual studio 8\vc\platformsdk\include\lmaccess.h 46 it's now complaining about something in lmaccess.h so you've likely included the headers too high up in your stdafx.h file. Make sure the includes are toward the bottom of the Wizard generated Include statements in stdafx.h to make sure the whole mess of other junk is in place before it attempts to include your api headers. Do a "rebuild all" to ensure everything gets taken into consideration. // All wizard generated stuff should be above this #include "Lm.h" #include "Lmjoin.h" #pragma comment(lib, "Netapi32")
-
Thank for your reply but it's same Error 1 error C2143: syntax error : missing ';' before '__stdcall' c:\program files\microsoft visual studio 8\vc\platformsdk\include\lmaccess.h 46 Regards, Daavena
-
Thank for your reply but it's same Error 1 error C2143: syntax error : missing ';' before '__stdcall' c:\program files\microsoft visual studio 8\vc\platformsdk\include\lmaccess.h 46 Regards, Daavena