Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Determining Display Name
#1
Hi Gintaras,
Under Display properties in Windows, under the Settings Tab, there is a listing of the Display monitors attached to the computer. Is it possible to get these names in a function?
e.g. "Barco MG7879" or "Dell U240" etc. Sometimes it will just say default monitor but that's ok.
Thanks, S
#2
This should get monitor name, but it is "Generic PnP Monitor", not true name.
Macro get names of video cards and monitors
Code:
Copy      Help
out
DISPLAY_DEVICE d.cb=sizeof(d)
DISPLAY_DEVICE dd.cb=sizeof(dd)
for _i 0 1000000
,if(!EnumDisplayDevices(0 _i &d 0)) break
,if(d.StateFlags&DISPLAY_DEVICE_ATTACHED_TO_DESKTOP=0) continue
,lpstr s=&d.DeviceString
,out "card: %s" s
,if EnumDisplayDevices(&d.DeviceName 0 &dd 0)
,,s=&dd.DeviceString
,,out "monitor: %s" s
#3
This works perfect. Thanks as always!!!
S


Forum Jump:


Users browsing this thread: 1 Guest(s)