Jump to content

Whats wrong with this script?


Recommended Posts

This scripts is the last <FirstLogonCommands> task. It launches properly but quits right after "echo *** DELETING TEMPORARY FILES", so none of the desktop items r excluded, Windows doesnt reboot after either and RunOnceEx script isnt added to registry. Whats wrong with it?


@echo off
color A0

start /wait c:\windows\system32\cleanmgr.exe /sagerun: 100
echo *** CCLEANER
start "CCLEANER" /wait "C:\Program Files\CCleaner\CCleaner64.exe" /AUTO
DEL /F /Q "%systemdrive%\Appz\*.*"
RD /S /Q "%systemdrive%\Appz"
DEL /F /Q /A:H "%Public%\Desktop\desktop.ini"
DEL /F /Q /A:H "%UserProfile%\Desktop\desktop.ini"
DEL /F /Q /A:H "%UserProfile%\Desktop\desktop.ini
DEL /F /Q "%UserProfile%\Desktop\Easy Duplicate Finder.lnk"
DEL /F /Q "%UserProfile%\Desktop\UltraISO.lnk"
DEL /F /Q "%UserProfile%\Desktop\Driver Genius Professional Edition.lnk"
DEL /F /Q "%UserProfile%\Desktop\Google Chrome.lnk"
DEL /F /Q "%Public%\Desktop\Adobe Content Viewer.lnk"
DEL /F /Q "%Public%\Desktop\Adobe Acrobat X Pro.lnk"
DEL /F /Q "%Public%\Desktop\Microsoft LifeCam.lnk"
DEL /F /Q "%Public%\Desktop\Nero MediaHub 10.lnk"
DEL /F /Q "%Public%\Desktop\Nero Burning ROM 10.lnk"
DEL /F /Q "%Public%\Desktop\Nero Vision 10.lnk"
DEL /F /Q "%Public%\Desktop\Yahoo! Messenger.lnk"
DEL /F /Q "%Public%\Desktop\EASEUS*.lnk"
DEL /F /Q "%Public%\Desktop\EASEUS Partition Master 9.0 Server Edition.lnk"
DEL /F /Q "%Public%\Desktop\HP Photosmart Essential 3.5.lnk"
DEL /F /Q "%Public%\Desktop\Mozilla Firefox.lnk"
DEL /F /Q "%Public%\Desktop\PC Inspector File Recovery.lnk"
DEL /F /Q "%Public%\Desktop\Wise PC Engineer.lnk"
DEL /F /Q "%Public%\Desktop\CCleaner.lnk"
DEL /F /Q "%Public%\Desktop\CPUID CPU-z.lnk"
DEL /F /Q "%UserProfile%\Desktop\desktop.ini"
DEL /F /Q "C:\Program Files\desktop.ini"
shutdown.exe -r -f -t 30 -c "O Sistema será reiniciado em 30 segundos."

Link to comment
Share on other sites

Actually, he should be able to just delete the line with the missing ("). It seems to be a duplicate line. He also should have noticed what the problem was as soon as he read over his own post since the forum software changed the color of all the lines below it, indicating that it was "reversing" the command and parameter portions of each line.

Cheers and Regards

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...