I need to know the type of the monitor(s) -- ie flat screen, CRT, etc -- that is used by the computer from a C++ program. The main requirement is for this code to work on Windows XP SP3 (because otherwise it's almost a given that the system runs on an LCD screen.)
I need it to implement screen dimming to save energy, which will work only on CRTs and have an opposite effect on flat screens.
Any idea how to do this?
You can get the most of the Information of Monitor by using the GetMonitorInfo function in Win32 API
BOOL GetMonitorInfo(
__in HMONITOR hMonitor,
__out LPMONITORINFO lpmi
);
This will give the output to the structure MONITORINFO or MONITORINFOEX where u can extract the information regarding the Current Attached Monitor
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.