Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

_WinAPI_GetGuiResources for GDI Object Count

$
0
0
I'm trying to get a GDI Object count using the _WinAPI_GetGuiResources function. From what I understand, I should use the 0 flag to get a count of GDI Objects. The 2nd parameter is the PID. When I run the code below, I get the following output:


Output:

PID: 2836

GDI Objects: 0




I know that PID 2836 is associated with 4 GDI Objects (according to TaskMan).

Any thoughts why this code isn't returning the correct number of GDI Objects?



[ autoit ]      
#include <Array.au3>; Only for _ArrayDisplay() #include <Date.au3> #include <WinAPI.au3> #include <File.au3> #include <_ArraySize.au3> Global Const $GR_GDIOBJECTS = 0 Local $PID = 2836 ;WinGetProcess("RD Tabs") consolewrite(@crlf & "PID: " & $PID & @crlf & "GDI Objects: " & _WinAPI_GetGuiResources($GR_GDIOBJECTS,$PID) & @crlf & @CRLF) Exit

Viewing all articles
Browse latest Browse all 12506

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>