Is there a way to get the Process ID from the window's hWnd or get the hWnd of a window with a process id?

Thanks,