How can I use winapi in Qt
Solved
General and Desktop
-
I want include windows.h header. But I can't build my project. It report "undefined reference to _imp__GetDeviceCaps@8". I cannot use any winapi.
I use Qt5.8.0-mingw. How to fix It.@DongMK Hi
u must also link to the dll that gives the function.Eaxmple
https://msdn.microsoft.com/en-us/library/windows/desktop/dd144877(v=vs.85).aspxthe GetDeviceCaps lives in
Gdi32.lib (DLL)so you must add to your .pro file
LIBS += -lgdi32