Kaseya Community

get screen resolution in procedure

This question is not answered

I'd like to create a procedure that does the following:

IF screen width equal to or greater than 1080, then run procedure A

If screen width less than 1080, then run procedure B

What's the best way to do this?

All Replies
  • Almost impossible.

    because after x-time the Pc's often disconnect the screen ( turn off ) then the reported x-y is zero.

    + if they connect there laptop to external screen.. what then ?

    in wmi; (vbs)

    Set objWMIService = GetObject("winmgmts:\\.\root\CIMV2")

    Set colItems = objWMIService.ExecQuery( "SELECT * FROM Win32_DesktopMonitor",,48)

    For Each objItem in colItems

       Wscript.Echo "-----------------------------------"

       Wscript.Echo "Win32_DesktopMonitor instance"

       Wscript.Echo "-----------------------------------"

       Wscript.Echo "ScreenHeight: " & objItem.ScreenHeight

       Wscript.Echo "ScreenWidth: " & objItem.ScreenWidth


  • the workstation changing resolutions sometimes isn't that big of a deal for me.

    I get that, doing in in a script. My problem is figuring out how to get a Kaseya procedure to read the result.

  • If you can get the screen resolution from a VBS script - have it pass to a variable and then compare the variable to your 1080 width in the IF statement