I can use FindWindow
, but the name of the window changes every time I open it. So my question is, how can I either:
A) Find the PID of a window that contains 'x'
B) Find the PID a window with the name of the exe file?
Sorry if the question is obvious, new to C++. Thanks in advance!
About B/, you can get executable file name by GetWindowModuleFileName via its windows handle.