planoleg Posted September 2, 2007 Share Posted September 2, 2007 I'm trying to figure out how to delete all the icons (shortcuts) from the desktop along with the folder created in start menu of a particular program. So I need the commands which to put in WPI in order to have shortcuts and folder in start menu deleted. I didn't find any clear answer on this forum and I have no idea how to attain my goal. If you could post your commands so I can understand what to write in WPI commandline it would be appreciated Link to comment Share on other sites More sharing options...
DJPro Posted September 2, 2007 Share Posted September 2, 2007 (edited) You can use this commandline to delete the desktop shortcuts:del /s/q "%UserProfile%\Desktop\*.lnk"del /s/q "%AllUsersProfile%\Desktop\*.lnk"To delete shortcuts in startmenu use:DEL "%systemdrive%\Documents and Settings\All Users\Start Menu\Programs\YOUR PROGRAM.lnk" ---> fill in your programAnd for folders in start menu use:RD /S /Q "%systemdrive%\Documents and Settings\All Users\Start Menu\Programs\Games\" ---> will delete games folderput this in a .bat or .cmd file and use it in WPIGreetz, DJPro Edited September 2, 2007 by DJPro Link to comment Share on other sites More sharing options...
planoleg Posted September 2, 2007 Author Share Posted September 2, 2007 Thanks a lot, it works fine, though I had to use %UserProfile% almost all the time or it didn't delete.I figure that writing RD /S /Q "%systemdrive%\Documents and Settings\All Users\Start Menu\Programs\ deletes all the folders at once. By the way, what means RD?I wonder why if I write these commands in WPI they don't work? I would be more convenient than having a .cmd file. Thanks for help again, and I would be glad still if people could post their WPI commands. I have 10 lines there, I use only 1 to install a program, I could probably write something useful in the rest of them Link to comment Share on other sites More sharing options...
DJPro Posted September 2, 2007 Share Posted September 2, 2007 RD = Removes DirectoryRMDIR is a synonym for RDGlad to help you! Link to comment Share on other sites More sharing options...
lawrenca Posted September 4, 2007 Share Posted September 4, 2007 This code would delete a directory called "Test1" from the desktop of the current user within WPI. Add it to a command on the config page.DELDIR "%UserProfile%\Desktop\Test1" 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