Can someone tell me how to get the handle of a Windows console application in C#? In a Windows Forms application, I would normally try this.Handle
.
Not sure it works, but you can try that :
IntPtr handle = Process.GetCurrentProcess().MainWindowHandle;