Systems By Posted June 28, 2006 Share Posted June 28, 2006 (edited) Hi everyone. I need to do a simple change with the following code: For $x = $aRecords[0] To 6 Step - 1 $aRecords[$x] = StringStripWS($aRecords[$x],3) If Not FileExists($homepcbudir &$aRecords) Then MsgBox(64, 'Info', 'File ' & $homepcbudir & $aRecords[$x] & ' Does not exist') If $aRecords[$x] <> "" Then Do FileDelete($homepcbudir & $aRecords[$x]) ToolTip('On this file:' & @CR & $homepcbudir & $aRecords[$x], 0, 0) Sleep(500) Until Not FileExists($homepcbudir & $aRecords[$x]) ;SplashTextOn("Autobackup", "Deleting " & $home & $aRecords[$x], 200, 150) Sleep(200) ;SplashOff() EndIf Next Is it possible to modify this line: For $x = $aRecords[0] To 6 Step - 1 so that the program performs the for statement on the first four files in the array only? I have looked all over and although it's probably the easiest thing to do, I am having a hard time doing the modification. Thanks. Edited June 28, 2006 by Systems By Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted June 28, 2006 Moderators Share Posted June 28, 2006 For $x = 1 To 4? Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Systems By Posted June 28, 2006 Author Share Posted June 28, 2006 For $x = 1 To 4? Thanks SmOke_N, I knew it was something easy. I think it's just too hot, I can't think too well 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