Adam12 Posted March 7, 2006 Share Posted March 7, 2006 OK I have been tryin for a couple hours now to write a script that will copy a folder fro my flash drive to the desktop of the current user. I think I must be missing something simple. I am trying to use @ScriptDir because as I plug my flash drive in different computers the Drive letter is not always the same so I can't use something like : DirCopy ( "g:\Test", ""& @HomeDrive & @HomePath &"\Desktop\Test" ,1 ) this is what I have tried DirCopy ( ""& @ScriptDir &"\Test", ""& @HomeDrive & @HomePath &"\Desktop\Test" ,1 ) DirCopy ( ""& @workingdir &"\Test", ""& @HomeDrive & @HomePath &"\Desktop\Test" ,1 ) does anyone know what I am doing wrong? the test folder is in the root of my flash drive. Link to comment Share on other sites More sharing options...
Stumpii Posted March 7, 2006 Share Posted March 7, 2006 (edited) You probably want: DirCopy ( @ScriptDir &"\Test", @DesktopDir & "\test" ,1) Edited March 7, 2006 by Stumpii Give a man a script; you have helped him for today. Teach a man to script; and you will not have to hear him whine for help.AutoIt4UE - Custom AutoIt toolbar and wordfile for UltraEdit/UEStudio users.AutoIt Graphical Debugger - A graphical debugger for AutoIt.SimMetrics COM Wrapper - Calculate string similarity. Link to comment Share on other sites More sharing options...
Adam12 Posted March 7, 2006 Author Share Posted March 7, 2006 Thanks! I knew it was prob something simple Link to comment Share on other sites More sharing options...
MHz Posted March 7, 2006 Share Posted March 7, 2006 @Adam12 You were fail with inserting a backslash between @HomeDrive and @HomePath, as Macro's do not end with a trailing backslash. Stumpii has the best method. 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