Lua:getWindow

From Cheat Engine
Revision as of 08:06, 9 July 2023 by Kagato1980 (talk | contribs) (fix typo)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Microsoft documentation


HWND GetWindow(
 [in] HWND hWnd,
 [in] UINT uCmd
);

Example[edit]

Start Cheat Engine and open a Memory Viewer, then go to the Lua Engine and execute this:

local hwnd = findWindow(null, "Lua Engine")
local memViewer = getWindow(hwnd, GW_HWNDNEXT)
local childCaption = getWindowCaption(memViewer)
print(hwnd, memViewer, childCaption)

Output should be like this:

1835872 328890 Memory Viewer