#include <wininet.h>
int main()
{
auto res = InternetAttemptConnect(0);
return 0;
}
Error I’m getting (I use code::blocks):
undefined reference to `InternetAttemptConnect@4’|
Any one knows what library (which file) do I need to specify in linker settings to make it work?
At run-time your program will use the DLL, but at build-time you must link to the LIB associated with the DLL.
The LIB will be is in your compiler/SDK directory (and the paths to directories which contain your LIB files is a linker option).