Svolpato Posted April 20, 2011 Share Posted April 20, 2011 HelloI'm using this:_ScreenCapture_Capture(@MyDocumentsDir & "\Images\file.jpg", 325, 278, 955, 689)Well, it's working, I can save the screenshot, but when I try to save the second screenshot using the same command, it overwrites the first screen and save the second.I want something like this:_ScreenCapture_Capture(@MyDocumentsDir & "\Images\file_X.jpg", 325, 278, 955, 689)the _X, will change to _1, _2, and so on.Can someone help me? Thx Link to comment Share on other sites More sharing options...
UEZ Posted April 20, 2011 Share Posted April 20, 2011 (edited) User a variable and increase the value! Example: ... $i = 0 ... _ScreenCapture_Capture(@MyDocumentsDir & "\Images\file_" & $i & ".jpg", 325, 278, 955, 689) $i += 1 ... Br, UEZ Edited April 20, 2011 by UEZ Please don't send me any personal message and ask for support! I will not reply! Selection of finest graphical examples at Codepen.io The own fart smells best! ✌Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!¯\_(ツ)_/¯ ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ Link to comment Share on other sites More sharing options...
wakillon Posted April 20, 2011 Share Posted April 20, 2011 welcome to the forums ! Try :$i=0 Do $i += 1 Until Not FileExists ( @MyDocumentsDir & "\Images\file_" & $i & " .jpg" ) _ScreenCapture_Capture(@MyDocumentsDir & "\Images\file_" & $i & " .jpg", 325, 278, 955, 689) AutoIt 3.3.14.2 X86 - SciTE 3.6.0 - WIN 8.1 X64 - Other Example Scripts Link to comment Share on other sites More sharing options...
UEZ Posted April 20, 2011 Share Posted April 20, 2011 As you can see $i is very populare. Br,UEZ Please don't send me any personal message and ask for support! I will not reply! Selection of finest graphical examples at Codepen.io The own fart smells best! ✌Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!¯\_(ツ)_/¯ ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ Link to comment Share on other sites More sharing options...
Svolpato Posted April 20, 2011 Author Share Posted April 20, 2011 UEZ and wakillon, thank you ^^ worked well bye 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