tonysing Posted October 17, 2014 Share Posted October 17, 2014 Hi guys, I am trying to copy a folder(with loads of stuff related to java) from one harddisk to another one. But things goes wrong even with this simple script. This is the main part: RunWait(@ComSpec & ' /c Xcopy /S/I/E/Y/T ' & $deploymentFolder_2008 & " " & $AppDataLocalLow) The targeted folder is quite large (100-200MB). The script will run automatically every time when the someone has logged on. It turns out that it only create a empty folder and copy one file for me. However, at the moment I test it, it has no issue at all. I wonder what make it goes wrong. Admin right? File size? Or something else? I have try to do the same thing with dircopy/filecopy, but it gives the same behavior. DirCopy($deploymentFolder_2008, $AppDataLocalLow,1) Link to comment Share on other sites More sharing options...
jguinch Posted October 17, 2014 Share Posted October 17, 2014 Try to add double quotes for the source and destination : RunWait(@ComSpec & ' /c Xcopy /S/I/E/Y/T "' & $deploymentFolder_2008 & '" "' & $AppDataLocalLow & '"') Is there an error with xcopy ? what is the resut of the command (with /k instead of /c) ? Spoiler Network configuration UDF, _DirGetSizeByExtension, _UninstallList Firefox ConfigurationArray multi-dimensions, Printer Management UDF Link to comment Share on other sites More sharing options...
tonysing Posted October 17, 2014 Author Share Posted October 17, 2014 (edited) When I use dircopy, it does has return an error code. But for xcopy, no error message at all. When I run the script with your change, still nothing change. The script give a clean cmd window pop out, without any running code on it Now not the clean thing, the cmd windows shows File not found - Common Edited October 17, 2014 by tonysing 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