Hi all,

When I tried to build my test code,it prompts this error: undefined reference to GetAdaptersInfo@8 although I've included iphlpapi.h....

The following is my test code eg:
Qt Code:
  1. #include <QtCore/QCoreApplication>
  2. #include <windows.h>
  3. #include <iphlpapi.h>
  4. #include <stdio.h>
  5. #include <stdlib.h>
  6. #include <string.h>
  7. //#include <netcon.h>
  8.  
  9. PIP_ADAPTER_INFO pAdapterInfo;
  10. ULONG bufferLen;
  11.  
  12. int main(int argc, char *argv[])
  13. {
  14. QCoreApplication a(argc, argv);
  15.  
  16. if( GetAdaptersInfo(pAdapterInfo, &bufferLen) != ERROR_SUCCESS )
  17. {
  18.  
  19. }
  20.  
  21. return a.exec();
  22. }
To copy to clipboard, switch view to plain text mode 
Need some help with this...

Secondly,How do I include netcon.h and its required files for use in my application?I tried #include <netcon.h> but it says no such file or directory...

Thanks in advanced.