Several displays are connected to the computer (two). You need to make a screenshot of the running application. If the application window is open on the PrimaryScreen, then everything is in order. And if not ... Do not want to make screenshots of all displays. How to determine on which display the application window is open and, accordingly, only its image?
- And if the window is stretched for several? :) - D-side
- This will be the next question :-). - Konstantin Ryabtsev
- Read your question. Wrote somehow clumsily. The screenshot should be made from the application by pressing the corresponding button. How to determine from the application on which display it is open? - Konstantin Ryabtsev
|
1 answer
Try this way to determine on which display the window is open:
Screen screen = Screen.FromControl(this); //this is the Form class Found here
Regarding the screenshot of a specific screen:
Here it is advised to use Screen.AllScreens , and then transfer the desired display to CopyFromScreen Bounds .
|