Lua:findWindow

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

findWindow(classname OPTIONAL, caption OPTIONAL): windowhandle - Finds a window with the given classname and/or windowname

https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-findwindowa

print( findWindow("WTWindow", "Game") )

Because classname is optional, this will also work:

 print(findWindow(null, "Cheat Engine 7.4"))