Get handle in C++

C++
hwnd = FindWindow(NULL,(LPCWSTR)"NAMEOFWINDOW");
Source

Also in C++: