I found that code somewhere and I find it quite useful but I would like to find a way to make it work so it capture only the given window target. Maybe with a processID or W
Capture the active-form.
Private Sub tsbCamera_Click(sender As Object, e As EventArgs) Handles tsbCamera.Click
Dim bm As New Bitmap(Width, Height)
DrawToBitmap(bm, New Rectangle(0, 0, Width, Height))
Dim name As String = InputBox("Name it:")
bm.Save(Application.StartupPath & "\ScreenShot\" & name & ".png", System.Drawing.Imaging.ImageFormat.Png)
End Sub