I am making a screen capturing application and everything is going fine. All I need to do is capture the active window and take a screenshot of this active window. Does an
If you want to use managed code: This will capture any window via the ProcessId.
I used the following to make the window active.
Microsoft.VisualBasic.Interaction.AppActivate(ProcessId);
Threading.Thread.Sleep(20);
I used the print screen to capture a window.
SendKeys.SendWait("%{PRTSC}");
Threading.Thread.Sleep(40);
IDataObject objData = Clipboard.GetDataObject();