#F12:: PrintAndSave: Send, {PrintSCREEN} ; or !{PrintSCREEN} to capture the active window only DetectHiddenWindows, On Run, %A_WinDir%\System32\mspaint.exe, , hide UseErrorLevel If ErrorLevel = ERROR { MsgBox, 0, Message, The File %A_WinDir%\System32\MSPAINT.EXE not found.`nThe "Save" feature is impossible. ErrorLevel = Return } WinWait, ahk_class MSPaintApp, , 5 PostMessage, 0x111, 57637, 0, , ahk_class MSPaintApp MsgBox, 64, Message, The screen was captured. PostMessage, 0x111, 57604, 0, , ahk_class MSPaintApp WinWait, ahk_class #32770, FolderView, 2 WinGetTitle, SaveWinTitle, ahk_class #32770, FolderView SetTimer, WaitForClose, 500 DetectHiddenWindows, Off Return WaitForClose: IfWinNotExist, %SaveWinTitle% { Process, Close, MSPAINT.EXE SetTimer, WaitForClose, Off } Return
Screen capture and save to file
Started by
Landvermesser
, Aug 07 2005 04:40 PM
8 replies to this topic
This script use the Microsoft Paint to save the clipboards content.
#1
-
Posted 07 August 2005 - 04:40 PM
It's a nice use of a hidden window and PostMessage to make it work in the background!
Thanks for posting it.
Thanks for posting it.
#2
-
Posted 09 August 2005 - 07:02 PM
Grab is an excellent program that can be used instead of MS Paint to convert an image on the clipboard to a file.
There are many options, including conversion to black-an-white, which makes the file size much smaller, for using the script with automatic emailing to an administrator.
http://pages.videotr...les/capture.htm
There are many options, including conversion to black-an-white, which makes the file size much smaller, for using the script with automatic emailing to an administrator.
http://pages.videotr...les/capture.htm
#3
-
Posted 22 August 2005 - 05:20 AM
Very nice!
I'm wondering if there's a way to default a different folder location as well as perhaps JPEG instead of BMP?
Any ideas?
thanks.
jimbo
I'm wondering if there's a way to default a different folder location as well as perhaps JPEG instead of BMP?
Any ideas?
thanks.
jimbo
#4
-
Posted 25 October 2005 - 12:27 PM
If you have irfanview installed or are willing to install it, You can also have a look at my EasyCopy script (for link, see my signature).
#5
-
Posted 25 October 2005 - 12:43 PM
Ciao
toralf
I use the latest AHK version (1.1.15+)
Please ask questions in forum on ahkscript.org. Why?
For online reference please use these Docs.
toralf
I use the latest AHK version (1.1.15+)
Please ask questions in forum on ahkscript.org. Why?
For online reference please use these Docs.
Thanks, toralf, your script is much better as my and I use it. Can you make it with the default Windows DLLs? Not all peoples have the installed IfranView.
#6
-
Posted 26 October 2005 - 06:20 AM
My AHK project: http://landvermesser.tripod.com/
Any solution using IrfanView is highly recommended because IrfanView is very high quality software, is free, and has many options and features.
#7
-
Posted 26 October 2005 - 09:38 PM
Sorry, no I can't. Since I'm not familiar with DLLs. I only took some code from shimanov. He mentioned that all would be possible with DLL, but you have to ask him to help you.Can you make it with the default Windows DLLs? Not all peoples have the installed IfranView.
Another reason is not to reinvent the wheel.
BTW: I do not have irfanview installed myself, I just copied the irfanview.exe and the one of its dll to the script dir, done.
#8
-
Posted 28 October 2005 - 07:25 AM
Ciao
toralf
I use the latest AHK version (1.1.15+)
Please ask questions in forum on ahkscript.org. Why?
For online reference please use these Docs.
toralf
I use the latest AHK version (1.1.15+)
Please ask questions in forum on ahkscript.org. Why?
For online reference please use these Docs.