Hi folks. IPHlpApi is a lib and .h file in the SDKs and I'm trying to call it from MSVC6.
I get this: unresolved external symbol "unsigned long __stdcall GetAdaptersInfo(struct _IP_ADAPTER_INFO *,unsigned long *)" (?GetAdaptersInfo@@YGKPAU_IP_ADAPTER_INFO@@PAK@Z)
I had to take out the iphldapi.h header file because it contains all sorts of MS.net compiler specific stuff which doesnt work in msvc6, so I declared it all myself...
#define __out_bcount_opt(size) __allowed(on_parameter)
#define __inout __allowed(on_parameter)
__out_bcount_opt(*SizePointer) PIP_ADAPTER_INFO AdapterInfo,
__inout PULONG SizePointer
And I'm sure thats the problem, but I'm not sure how to fix it !!
I did add iphlpapi.lib to the list of linker libs, and I've ensured that the path to the lib is in the paths in tools>options.
This seems to work fine in later compilers, but I really need it to work in msvc6.