July 13, 200521 yr Hi all,As per the image below there are a number of links that I just can not get rid of:Remote AssistanceTour Windows XPCommand PromptProgram Compatabiltiy WizardSynchronizeWindows ExplorerAny idea on how to get rid of them...Below is my cleanup scriptcmdow @ /HID@echo off:: Start >>del "%ALLUSERSPROFILE%\Start Menu\New Office Document.lnk"del "%ALLUSERSPROFILE%\Start Menu\Open Office Document.lnk"del "%ALLUSERSPROFILE%\Start Menu\Set Program Access and Defaults.lnk"del "%ALLUSERSPROFILE%\Start Menu\Windows Catalog.lnk"del "%ALLUSERSPROFILE%\Start Menu\Windows Update.lnk":: Start >> Programs >>del "%ALLUSERSPROFILE%\Start Menu\Programs\Remote Assistance.lnk" [B]<-- This does not seem to work[/B]:: Start >> Programs >> Accessories >>del "%ALLUSERSPROFILE%\Start Menu\Programs\Accessories\Tour Windows XP.lnk" [B]<-- This does not seem to work[/B]del "%ALLUSERSPROFILE%\Start Menu\Programs\Accessories\Synchronize.lnk" [B]<-- This does not seem to work[/B]del "%ALLUSERSPROFILE%\Start Menu\Programs\Accessories\Program Compatability Wizard.lnk" [B]<-- This does not seem to work[/B]del "%ALLUSERSPROFILE%\Start Menu\Programs\Accessories\Command Prompt.lnk" [B]<-- This does not seem to work[/B]rd /s /q "%ALLUSERSPROFILE%\Start Menu\Programs\Accessories\System Tools"rd /s /q "%ALLUSERSPROFILE%\Start Menu\Programs\Accessories\Communications"DEL "%systemroot%\*.bmp"DEL "%systemroot%\system32\dllcache\*.scr"DEL "%systemroot%\system32\*.scr"RD /S /Q %systemdrive%\I386\$OEM$\RD /S /Q %systemdrive%\install\RD /S /Q %systemdrive%\Logfiles\net user aspnet /deleteshutdown.exe -r -f -t 5 -c "Windows will now restart...."EXIT
July 13, 200521 yr It's probably because some of the links are located in your user folder %userprofile%
July 13, 200521 yr Author The links need to be removed from the all users profile, now when manually checking the are there and do reside if the paths as specified in my script above.But still only some are removed.
July 13, 200521 yr I have a "Command Prompt.lnk" in my users accessories folder anyway, and i guess it's created by default for each user on the system.You you could put the del lines in each users logon script.Or else maybe you could remove the links from the hidden "C:\Documents and Settings\Default User" folder. I presume this folder is the skeleton folder for all users logging on the system for the first time. Edited July 13, 200521 yr by allan
July 13, 200521 yr I reviewed your batch. This is what I finished with.cmdow @ /HID@echo off:: Start >>set AUPSM="%ALLUSERSPROFILE%\Start Menu"del "%AUPSM%\New Office Document.lnk"del "%AUPSM%\Open Office Document.lnk"del "%AUPSM%\Set Program Access and Defaults.lnk"del "%AUPSM%\Windows Catalog.lnk"del "%AUPSM%\Windows Update.lnk":: Start >> Programs >>set UPSMP="%USERPROFILE%\Start Menu\Programs"del "%UPSMP%\Remote Assistance.lnk":: Start >> Programs >> Accessories >>set AUPSMPA="%ALLUSERSPROFILE%\Start Menu\Programs\Accessories"rd /s /q "%AUPSMPA%\System Tools"rd /s /q "%AUPSMPA%\Communications"set UPSMPA="%USERPROFILE%\Start Menu\Programs\Accessories"del "%UPSMPA%\Tour Windows XP.lnk"del "%UPSMPA%\Program Compatability Wizard.lnk"del "%UPSMPA%\Synchronize.lnk"del "%UPSMPA%\Command Prompt.lnk"DEL "%systemroot%\*.bmp"DEL "%systemroot%\system32\dllcache\*.scr"DEL "%systemroot%\system32\*.scr"RD /S /Q %systemdrive%\I386\$OEM$\RD /S /Q %systemdrive%\install\RD /S /Q %systemdrive%\Logfiles\net user aspnet /deleteshutdown.exe -r -f -t 5 -c "Windows will now restart...."EXITThe guys are correct, that you are are choosing the wrong profile directories.
July 13, 200521 yr Have you looked in the 'Default User' profile folder?<Edit>All of the following lnks are found there:Remote AssistanceTour Windows XPCommand PromptProgram Compatabiltiy WizardSynchronizeWindows Explorer</Edit>Here is an example of a way round not knowing for sure in which profile your file /folder is located@echo off&setlocal enableextensionsfor /f "delims=" %%a in ('dir /b/s/ad "%AllUsersProfile%\..\*"') do if exist "%%~a\Start Menu" call :gothere "%%~a\Start Menu"endlocal&goto :eof:gotherepushd %1:: your profile dependent stuff [changed] heredel /q/s "New Office Document.lnk" 2>nuldel /q/s "Open Office Document.lnk" 2>nuldel /q/s "Set Program Access and Defaults.lnk" 2>nuldel /q/s "Windows Catalog.lnk" 2>nuldel /q/s "Windows Update.lnk" 2>nuldel /q/s "Remote Assistance.lnk" 2>nuldel /q/s "Tour Windows XP.lnk" 2>nuldel /q/s Synchronize.lnk 2>nuldel /q/s "Program Compatability Wizard.lnk" 2>nuldel /q/s "Command Prompt.lnk" 2>nulrd /s/q "Programs\Accessories\System Tools" 2>nulrd /s/q "Programs\Accessories\Communications" 2>nulpopd&goto :eof Edited July 13, 200521 yr by Yzöwl
July 13, 200521 yr Some of "visual points" are removed through StubPath in registry (for example Outlook Express)
July 24, 200521 yr can someone please give an example of what the command would look like, to get rid of the Outlook Express.lnk file (in start menu)and the Internet Explorer.lnk, would be nice to. for the default user, and all future accounts created. (not %userprofile%).
July 25, 200521 yr Thats a FAQ.rem Hide IE and OE icons (Win2000)rem "%SystemRoot%\system32\rundll32.exe" "%SystemRoot%\system32\shell32.dll",OCInstall HideIErem "%SystemRoot%\system32\rundll32.exe" "%SystemRoot%\system32\shell32.dll",OCInstall HideOE rem Hide IE and Outlook Express icons (WinXP)"%SystemRoot%\System32\shmgrate.exe" OCInstallHideIE"%SystemRoot%\System32\shmgrate.exe" OCInstallHideOE Edited July 25, 200521 yr by Dahi
July 25, 200521 yr I used nLite to do most of those little tweaks. It seemed to work just fine for me to get rid of useless links like that. Giver a try!! B)
Create an account or sign in to comment