Cameltoe Posted January 11, 2010 Share Posted January 11, 2010 (edited) Hello, i'm making a logging script. the script will be able to save screen captures to a spesified folder with hour and min in the name of image file. here is the script #include <ScreenCapture.au3> $file = "C:\Documents and Settings\Administrator\Desktop\Scripts\MN\Screenshot" $random = @hour $random2 = @min _Main() Func _Main() Local $jpg $jpg = ("Screen Capture") ; Capture window _ScreenCapture_Capture($file & $random & $random2 "\.jpg", $jpg) EndFunc ;==>_Main where i need help is at the $random part. i want $random & $random2 variables to write the time in the name of the image. ty all in advance! Edited January 11, 2010 by Cameltoe Link to comment Share on other sites More sharing options...
Cameltoe Posted January 11, 2010 Author Share Posted January 11, 2010 Please somone! im using this ctrl-c to notepad and that is using much of the time.... Link to comment Share on other sites More sharing options...
JonathanR Posted January 11, 2010 Share Posted January 11, 2010 Way to make that WAY more complicated than need be. Just use the @HOUR and @MIN macros right in the _ScreenCapture_Capture function. Also, it'd probably help if you use the correct syntax for the functions. ($jpg ..?) #include <ScreenCapture.au3> $file = "C:\Documents and Settings\Administrator\Desktop\Scripts\MN\Screenshot" _ScreenCapture_Capture($file & @HOUR & @MIN & ".jpg") This will create a screen capture: "C:\Documents and Settings\Administrator\Desktop\Scripts\MN\ScreenshotHHMM.jpg" Link to comment Share on other sites More sharing options...
Cameltoe Posted January 11, 2010 Author Share Posted January 11, 2010 (edited) Ty sooo much!! ima test it now ------Edit------ It worked really fine! ty bigtime Edited January 11, 2010 by Cameltoe Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now