Rex Posted November 15, 2005 Posted November 15, 2005 (edited) Hi im trying to create a script that moves my favorites+documents folders to a nother folder/drive But when i run the script nothing happens Here's my code $Drive_1 = "D:" $Folder_1 = "Profile" $User_1 = "My Name" DirMove(@Mydocumentsdir, $drive_1 & "\" &$Folder_1 & "\" & $User_1) DirMove(@FavoritesDir, $drive_1 & "\" & $Folder_1 & "\" & $User_1) What am i doing wrong ???? :EDIT > TypO _ :EDIT2 > DirCopy >> DirMove Edited November 15, 2005 by Rex
SpookMeister Posted November 15, 2005 Posted November 15, 2005 DirCopy(@FavoritesDir, $drive_1 & "\" & $Folder_1 & "\" & $User_1)also.. I would make them go to different directories instead of smushing them all together. [u]Helpful tips:[/u]If you want better answers to your questions, take the time to reproduce your issue in a small "stand alone" example script whenever possible. Also, make sure you tell us 1) what you tried, 2) what you expected to happen, and 3) what happened instead.[u]Useful links:[/u]BrettF's update to LxP's "How to AutoIt" pdfValuater's Autoit 1-2-3 Download page for the latest versions of Autoit and SciTE[quote]<glyph> For example - if you came in here asking "how do I use a jackhammer" we might ask "why do you need to use a jackhammer"<glyph> If the answer to the latter question is "to knock my grandmother's head off to let out the evil spirits that gave her cancer", then maybe the problem is actually unrelated to jackhammers[/quote]
eJan Posted November 15, 2005 Posted November 15, 2005 Try with flag (1) $Drive_1 = "D:" $Folder_1 = "Profile" $User_1 = "My Name" DirCopy(@Mydocumentsdir, $drive_1 & "\" &$Folder_1 & "\" & $User_1, 1) DirCopy(@FavoritesDir, $drive_1 & "\" & $Folder_1 & "\" & $User_1, 1)
Rex Posted November 15, 2005 Author Posted November 15, 2005 Woops it was my test code i posted i can see, it shoould bee dirmove insted of dir copy and the _ missing is just a typO in the post, it in my org script, so edit my post to fix typO LOL
Rex Posted November 15, 2005 Author Posted November 15, 2005 Try with flag (1)$Drive_1 = "D:" $Folder_1 = "Profile" $User_1 = "My Name" DirCopy(@Mydocumentsdir, $drive_1 & "\" &$Folder_1 & "\" & $User_1, 1) DirCopy(@FavoritesDir, $drive_1 & "\" & $Folder_1 & "\" & $User_1, 1)Have tryed that to, but it ain't working
SpookMeister Posted November 15, 2005 Posted November 15, 2005 (edited) Those work in my testing... I havent tried with DirMove because.. I don't want to move those files. In fact I'm curious why you would want to. Edit: Now that I think of it.. perhaps the reason you cant move your profile is because of sharing violations (you are actively using your profile) Edited November 15, 2005 by SpookMeister [u]Helpful tips:[/u]If you want better answers to your questions, take the time to reproduce your issue in a small "stand alone" example script whenever possible. Also, make sure you tell us 1) what you tried, 2) what you expected to happen, and 3) what happened instead.[u]Useful links:[/u]BrettF's update to LxP's "How to AutoIt" pdfValuater's Autoit 1-2-3 Download page for the latest versions of Autoit and SciTE[quote]<glyph> For example - if you came in here asking "how do I use a jackhammer" we might ask "why do you need to use a jackhammer"<glyph> If the answer to the latter question is "to knock my grandmother's head off to let out the evil spirits that gave her cancer", then maybe the problem is actually unrelated to jackhammers[/quote]
Rex Posted November 15, 2005 Author Posted November 15, 2005 Those work in my testing... I havent tried with DirMove because.. I don't want to move those files. In fact I'm curious why you would want to.Edit:Now that I think of it.. perhaps the reason you cant move your profile is because of sharing violations (you are actively using your profile)When i setting up coputers i'm using a Creat User script i createded longago, and now i'm trying to update the script so i moves the users fav. and doc's to the profile folder i have created on a nother drive, but i too think that you are right, that the reason the i can't move the documents folder is becorse of i's a sys folder...But not even vith the dircopy i can move the folders... And al i wat to is to put C:\Doc...\...\my documents and C:\Doc...\...\Favorites to D:\Profile\Documets + D:\Profile\Favorites
SpookMeister Posted November 15, 2005 Posted November 15, 2005 This works for me.. it took a while the first time, but thats because my "My Documents" folder is huge. Opt("TrayIconDebug", 1);0=no info, 1=debug line info $Drive_1 = "D:" $Folder_1 = "Profile" $User_1 = "My Name" DirCopy(@Mydocumentsdir, $drive_1 & "\" &$Folder_1 & "\" & $User_1 & "\" & "docs") DirCopy(@FavoritesDir, $drive_1 & "\" & $Folder_1 & "\" & $User_1 & "\" & "favs") Does the copy work for you, but the move does not? [u]Helpful tips:[/u]If you want better answers to your questions, take the time to reproduce your issue in a small "stand alone" example script whenever possible. Also, make sure you tell us 1) what you tried, 2) what you expected to happen, and 3) what happened instead.[u]Useful links:[/u]BrettF's update to LxP's "How to AutoIt" pdfValuater's Autoit 1-2-3 Download page for the latest versions of Autoit and SciTE[quote]<glyph> For example - if you came in here asking "how do I use a jackhammer" we might ask "why do you need to use a jackhammer"<glyph> If the answer to the latter question is "to knock my grandmother's head off to let out the evil spirits that gave her cancer", then maybe the problem is actually unrelated to jackhammers[/quote]
MHz Posted November 16, 2005 Posted November 16, 2005 (edited) If you want to move Shell folders then you may need to do more as to create the destination folder 1st, change the pointer in registry and then move the contents over to the new destination. Registry key to look at: HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders Also, Winnt.sif has a setting for setting the profile elsewhere during Windows setup. [GuiUnattended] ProfilesDir="D:\Documents and Settings\" Also, the resource tools that Microsoft releases may have a commandline tool that deals with Shell folders. Edited November 16, 2005 by MHz
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