Capture screenshot of active window?

前端 未结 11 2236
春和景丽
春和景丽 2020-11-21 23:34

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

11条回答
  •  离开以前
    2020-11-22 00:27

    You can use the code from this question: How can I save a screenshot directly to a file in Windows?

    Just change WIN32_API.GetDesktopWindow() to the Handle property of the window you want to capture.

提交回复
热议问题