April 4, 200620 yr How come this command does not work when called from a *.cmd file. But i can copy it directly into the command window and it works properly?MOVE /Y "%AllUsersProfile%\Start Menu\Programs\Alcohol 120%" "%AllUsersProfile%\Start Menu\Programs\CD-Burn"
April 4, 200620 yr In a batch file the command would be:MOVE "%AllUsersProfile%\Start Menu\Programs\Alcohol 120%%" "%AllUsersProfile%\Start Menu\Programs\CD-Burn"
April 5, 200620 yr Author What are the syntax for all the users userprofile, alluser etc? Does anyone have that?See that worked just fine...But now when i tryMOVE "%AllUsersProfile%\Start Menu\Programs\Norton AntiVirus%" "%AllUsersProfile%\Start Menu\Programs\System"Nothjing happens
April 5, 200620 yr What Yzöwl was saying was not to add a % sign at the end of your path, but to double any % sign there may be in it.that's because % sign are used for variables (like %AllUsersProfile%).
April 5, 200620 yr What are the syntax for all the users userprofile, alluser etc? Does anyone have that?See that worked just fine...But now when i tryMOVE "%AllUsersProfile%\Start Menu\Programs\Norton AntiVirus%" "%AllUsersProfile%\Start Menu\Programs\System"Nothjing happensYou have a extta % one of these at the end of Norton AntiVirus%, this would be my guess.If you feel comfortable using VBS script here one that in therory should work.Here is a brief explanation of the below script1:\ It checks for this folder All_UP & "\System\"If it there then it copyies norton then deletes the original location of nortons.2:\ If this folder does not exists All_UP & "\System\" thenit makes a that folder then it copies nortons then deletes nortons.I have tested this and The Norton Folder ended up in the System Folder and the original Nortons folders was deleted.Dim Act : Set Act = CreateObject("Wscript.shell") Dim Fso : Set Fso = CreateObject("Scripting.FileSystemObject") Dim All_UP : All_UP = Act.ExpandEnvironmentStrings("%AllUsersProfile%\Start Menu\Programs\") Dim MoveThis,MoveHere : MoveThis = All_UP & "\Norton AntiVirus" : MoveHere = All_UP & "\System\" If Fso.FolderExists(MoveHere) Then Fso.CopyFolder MoveThis, MoveHere : Fso.DeleteFolder(MoveThis) End If If Not Fso.FolderExists(MoveHere) Then Fso.CreateFolder(MoveHere): Fso.CopyFolder MoveThis, MoveHere : Fso.DeleteFolder(MoveThis) End If
Create an account or sign in to comment