PdhOpenQuery eror
-
@#include <windows.h>
#include <pdh.h>
#include <pdhmsg.h>
static HQUERY hQuery;
PdhOpenQuery(NULL, 0, &hQuery);@Hello everyone. in Qt insert this code and so we get an error "undefined reference to `PdhOpenQueryW@12' "
how to solve this problem. thanks!! -
Hi and welcome to devnet,
Are you linking to the Pdh library ?
-
PdhOpenQuery is not a part of Qt, it's a Windows function given through the Pdh library, so if you want to use it you need to link to that library
-
hI all,
please suggest how to link pdh library. -
hI all,
please suggest how to link pdh library. -
Hi,
@LIBS += -lPdh@
-
Hi,
@LIBS += -lPdh@
-
Thank you.
-
Thank you.