The FindWindow function retrieves the handle to the top-level window whose class name and window name match the specified strings. This function does not search child windows.

number FindWindow(

string lpClassName, --class name of window
string lpWindowName --name of window
);

Parameters

lpClassName

Class name of the window to find set "" if not needed

lpWindowName

specifies the window name (the window's title). If this parameter is "" all window names match.

Return Values

If the function succeeds, the return value is the handle to the window that has the specified class name and window name.
If the function fails, the return value is 0.