title: error LNK2019: unresolved external symbol __imp__EnumDisplayDevicesA@16 referenced in function "private: struct _DISPLAY_DEVICEA __thiscall
body: <p>what am trying to do is getting my Screen info like resolution/refresh rate etc:</p>
  
  <pre><code>#pragma once
  #include &lt; windows.h &gt;
  #include &lt;string&gt;
  #include &lt;sstream&gt;
  
  struct DesktopScreenInfo
  {
      int Width;
      int Height;
      int ScreenDepth;
      int FrameRate;
      std::string ScreenInfoString;
  };
  
  class DesktopScreen
  {
  public:
      DesktopScreen(void);
      ~DesktopScreen(void);
  
      DesktopScreenInfo GetScreenInfo();
  private:
      DISPLAY_DEVICE GetPrimaryDevice();
  };
  
  #include "DesktopScreen.h"
  
  DesktopScreen::DesktopScreen(void)
  {
  }
  
  DesktopScreen::~DesktopScreen(void)
  {
  }
  
  DISPLAY_DEVICE DesktopScreen::GetPrimaryDevice(){
      int index=0;
      DISPLAY_DEVICE dd;
      dd.cb = sizeof(DISPLAY_DEVICE);
  
      while (EnumDisplayDevices(NULL, index++, &amp;dd, 0))
      {
          if (dd.StateFlags &amp; DISPLAY_DEVICE_PRIMARY_DEVICE) return dd;
      }
      return dd;
  }
  
  DesktopScreenInfo DesktopScreen::GetScreenInfo(){
      DISPLAY_DEVICE dd = GetPrimaryDevice();
      DesktopScreenInfo info;
      DEVMODE dm;
      dm.dmSize = sizeof(DEVMODE);
  
      if (!EnumDisplaySettings(dd.DeviceName, ENUM_CURRENT_SETTINGS, &amp;dm))
      {
          //printf("EnumDisplaySettings failed:%d\n", GetLastError());
          return info;
      }
      info.Width = dm.dmPelsWidth;
      info.Height = dm.dmPelsHeight;
      info.ScreenDepth = dm.dmBitsPerPel;
      info.FrameRate = dm.dmDisplayFrequency;
      std::stringstream ss;
      ss &lt;&lt; info.Width &lt;&lt; "x" &lt;&lt; info.Height &lt;&lt; ":" &lt;&lt; info.ScreenDepth &lt;&lt; "@" &lt;&lt; info.FrameRate;
      info.ScreenInfoString = ss.str();
  }
  </code></pre>
  
  <p>but when am trying to build it , it gives me this errors</p>
  
  <pre><code>Error   2   error LNK2019: unresolved external symbol __imp__EnumDisplayDevicesA@16 referenced in function "private: struct _DISPLAY_DEVICEA __thiscall DesktopScreen::GetPrimaryDevice(void)" (?GetPrimaryDevice@DesktopScreen@@AAE?AU_DISPLAY_DEVICEA@@XZ)
  Error   3   error LNK2019: unresolved external symbol __imp__EnumDisplaySettingsA@12 referenced in function "public: struct DesktopScreenInfo __thiscall DesktopScreen::GetScreenInfo(void)" (?GetScreenInfo@DesktopScreen@@QAE?AUDesktopScreenInfo@@XZ)
  </code></pre>
  
  <p>I have no clue what is wrong :S</p>