idle Posted December 22, 2003 Share Posted December 22, 2003 I have made a script which moves some files from one dir to another, and checks the errorcode. It works om my win2k machine, but when I was testing it on a win95 machine it failed to delete the file. I don't have a win95 machine mysqlf, so maybe someone could check if and see if its a bug? FileCopy("c:\dir1\*.ted", "c:\dir2\*.*",1) If @error = 0 then FileDelete("*.ted") Endif Link to comment Share on other sites More sharing options...
scriptkitty Posted December 22, 2003 Share Posted December 22, 2003 (edited) FileCopy("c:\dir1\*.ted", "c:\dir2\*.*",1) If @error = 0 then FileDelete("*.ted") Endif should it be?: FileCopy("c:\dir1\*.ted", "c:\dir2\*.*",1) If @error = 0 then FileDelete("c:\dir1\*.ted") Endif it might have been that the file was not executed in c:\dir1\ It worked fine on my Win95 machine. Edited December 22, 2003 by scriptkitty AutoIt3, the MACGYVER Pocket Knife for computers. Link to comment Share on other sites More sharing options...
sykes Posted December 23, 2003 Share Posted December 23, 2003 As posted by JdeB on 12/8/03:Just wanted to share with you that the filecopy returns its "returncode" into a variable .. not into @ERROR..You are correct that Filecopy doesn't return a 1 if theres nothing to copy...don't know why.....thats for the developers to answer. We have enough youth. How about a fountain of SMART? Link to comment Share on other sites More sharing options...
idle Posted December 23, 2003 Author Share Posted December 23, 2003 should it be?: FileCopy("c:\dir1\*.ted", "c:\dir2\*.*",1) If @error = 0 then FileDelete("c:\dir1\*.ted") EndifYou're right... Its me who have made a mastake. I just haven't seen it, as the files in in the same dir on the machine on which i'm testing it... 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