用ahk比较简单,需要gdip库- #Include Gdip.ahk
- #InstallMouseHook
- Path := "D:\a"
- ~LButton::
- If !(FileExist(Path))
- FileCreateDir,% Path
- pToken := Gdip_Startup()
- pBitmap := Gdip_BitmapFromScreen("0|0|" . A_ScreenWidth . "|" . A_ScreenHeight)
- screenFile := Path . "\" . A_Now . ".png"
- Gdip_SaveBitmapToFile(pBitmap, screenFile)
- Gdip_DisposeImage(pBitmap)
- Gdip_Shutdown(pToken)
- return
复制代码
|