Jump to content

%AllUsersProfile%


Recommended Posts

I have made my cleanup.cmd file with these commands:

DEL "%AllUsersProfile%\Start Menu\*.lnk"

DEL "%AllUsersProfile%\Start Menu\Programs\*.lnk"

rd /s /q "%AllUsersProfile%\Start Menu\Programs\Winamp"

rd /s /q "%AllUsersProfile%\Start Menu\Programs\Skype"

rd /s /q "%systemdrive%\Program Files\AOD"

rd /s /q "%systemdrive%\Program Files\AWS"

rd /s /q %systemdrive%\install

rd /s /q %systemdrive%\drivers

and surprisingly, only these two worked :

rd /s /q %systemdrive%\install

DEL "%AllUsersProfile%\Start Menu\*.lnk"

what do you think? does %AllUsersProfile% work? How come its not deleting the other repertories and links im asking him to?

For information, Cleanup.cmd is run via RunOnceEx.cmd which is ran by

cmdlines.txt

[COMMANDS]"useraccounts.cmd"

"batch_file.cmd"

"runonceex.cmd"

Link to comment
Share on other sites


perhaps it won't delete some of the folders because files are in use? (like the program files folders for example)

this is what I do and it works:

@echo off
Title Deleting crappy shortcuts

ECHO Deleting start menu shortcuts...

RD /S /Q "%AllUsersProfile%\Start Menu\Programs\PrintMe Internet Printing"
DEL "%AllUsersProfile%\Start Menu\Windows Update.lnk"
DEL "%AllUsersProfile%\Start Menu\Set Program Access and Defaults.lnk"
DEL "%AllUsersProfile%\Start Menu\Windows Catalog.lnk"
DEL "%AllUsersProfile%\Start Menu\Programs\Windows Movie Maker.lnk"
DEL "%AllUsersProfile%\Start Menu\Programs\Adobe Reader 6.0.lnk"
DEL "%UserProfile%\Start Menu\Programs\Windows Media Player.lnk"
DEL "%UserProfile%\Start Menu\Programs\Remote Assistance.lnk"

ECHO Deleting desktop shortcuts...

DEL "%AllUsersProfile%\Desktop\Adobe Reader 6.0.lnk"
DEL "%AllUsersProfile%\Desktop\CloneCD.lnk"
DEL "%AllUsersProfile%\Desktop\PowerDVD.lnk"
DEL "%AllUsersProfile%\Desktop\ISOBuster.lnk"
DEL "%AllUsersProfile%\Desktop\Nero StartSmart.lnk"
DEL "%AllUsersProfile%\Desktop\DAEMON Tools.lnk"
DEL "%AllUsersProfile%\Desktop\BSplayer.lnk"
DEL "%UserProfile%\Desktop\Ad-Aware 6.0.lnk"
DEL "%UserProfile%\Desktop\CDex.lnk"
DEL "%UserProfile%\Desktop\Winamp.lnk"

Note how some of mine aren't in %AllUsersProfile%? Maybe your stuff is in the %UserProfile% directory too?

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...