Jump to content

Recommended Posts

Posted

Hi this is my first post here and I just wanted some help in understanding some entries in CLEANUP.CMD in the RunOnceEx guide.

In the example CLEANUP.CMD has the following entries:

cmdow @ /HID
shutdown.exe -r -f -t 60 -c "Windows XP will now restart in 1 minute..."
net user aspnet /delete

DEL "%systemroot%\*.bmp"
DEL "%systemroot%\Web\Wallpaper\*.jpg"
DEL "%systemroot%\system32\dllcache\*.scr"
DEL "%systemroot%\system32\*.scr"

DEL "%AllUsersProfile%\Start Menu\Windows Update.lnk"
DEL "%AllUsersProfile%\Start Menu\Set Program Access and Defaults.lnk"
DEL "%AllUsersProfile%\Start Menu\Windows Catalog.lnk"

RD /S /Q %systemdrive%\drivers\
RD /S /Q %systemdrive%\install\

EXIT

Basically I am having trouble with lines 2 and 3. Wouldn't the SHUTDOWN command be better as the last line of code as in its present position the computer will shutdown before reaching the rest of the commands

What does "net user aspnet /delete" do? and is it necessary?

Sorry if these questions seem foolish but it is confusing me.


Posted

The -t 60 switch instructs shutdown.exe to do a 60sec countdown before restarting the PC, so no worries, the rest of the script will be parsed. If you still don't like this just move the shutdown line at the end.

The net user command deletes the aspnet account that was created when you installed the .Net framework if I am not mistaken ... You can remove it if you want and then check if the aspnet account is present in your system. If not, no need for that line ...

CF

Posted

actually it would not shut down for 1 minute, plenty of time for the other commands to run.

Net user aspnet /delete - deletes the user account aspnet

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