boniakowski Posted July 16, 2014 Share Posted July 16, 2014 Hello, and every week I have a new question. I mention them already done the search before and did not specifically find what I need. obviously i know, filecopy, dircopy, fileexist, etc... is simple but still do not understand how to implement it. Let's begin: I generate a local folder several txt files with a random name, and leaves the result that takes the date and exact time with their seconds, eg. 07162014112824.txt I need to copy these files which do not know the exact name so I explained before and move them to a folder on a server and at the same time check that folder if the file exists or has already copied to the server and if you delete it locally there is no copy (Do not forget I do not know the file name only extensions. txt) must take into account that is by wifi and there is a possibility of interruption or packet loss for a few minutes on the net, when I return make the request for a copy verify and copy. Got that? 's that simple but not how to do that routine. Thank you as always for your great support. Christian Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted July 16, 2014 Moderators Share Posted July 16, 2014 What have you tried on your own, how are you generating the folder and the files? Is the folder's name static? "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
boniakowski Posted July 16, 2014 Author Share Posted July 16, 2014 What have you tried on your own, how are you generating the folder and the files? Is the folder's name static? Yes the Local Folder it´s Static and the server folder too. local folder: c:anyname remote folder: anyname only generate random files.txt with the date and time. a hundred of files... file1=07162014112824.txt file2=07162014112843.txt file3=07162014113314.txt i must check if file1 it´s not in the server folder copy and remove from local folder if not wait to the connection wifi its up again and copy the files to the folder server and remove locally, every 2 or 3 seconds i must send the files if the connection wifi its up or wait to reconnect and then send the files. Link to comment Share on other sites More sharing options...
Solution jdelaney Posted July 16, 2014 Solution Share Posted July 16, 2014 Use: _FileListToArray IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window. Link to comment Share on other sites More sharing options...
lolipop Posted July 17, 2014 Share Posted July 17, 2014 Perhaps you can show us your script. It will be easier for others to advise you onward. Link to comment Share on other sites More sharing options...
boniakowski Posted July 17, 2014 Author Share Posted July 17, 2014 Use: _FileListToArray Perfect you open my mind. this its an sample becaus emy code it´s too long. and i only need help in this situation for the moment. both path are local because it´s only for test. i only need to change the root path for the maped server. #include <File.au3> #include <Array.au3> #include <MsgBoxConstants.au3> Example() Func Example() While 1 ; List all the files and folders in the desktop directory using the default parameters. Local $aFileList = _FileListToArray("C:\copiar", "*.txt") If @error = 1 Then MsgBox($MB_SYSTEMMODAL, "", "Path was invalid.") Exit EndIf If @error = 4 Then MsgBox($MB_SYSTEMMODAL, "", "No file(s) were found.") Exit EndIf ; Display the results returned by _FileListToArray. For $vElement In $aFileList FileMove("C:\copiar"&"\"&$vElement, "C:\copiar\copiar2\") Next WEnd EndFunc ;==>Example jdelaney Thank you very much for your help. 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