Jump to content

Recommended Posts

Posted

When the install is finished can I then delete the install folder that the inst. have made on C: ??

Can I do it with the cmd file that I use to install the oem folders with??


Posted

use something like this:

del \*FOLDERNAME* /s/q

run from root, like C:\

/s is for subdirectories

/q is no conformation/quite mode

Posted

okay...thanks

But will I get problem when I ad new user accounts??

Am I right about, that they wont get the reg. tweaks then?

  • 1 month later...
Posted

If i will use del \*FOLDERNAME* /s/q

can i then do it from my application.cmd as the last thing after installing all programs??

If yes.....

How do it have to look?

Like this:

application.cmd file.......

-

-

-

-

ECHO Applying Registry Tweaks...

REGEDIT /S %systemdrive%\install\RegTweaks.reg

ECHO.

del C:\*install* /s/q

echo

Posted

I think it's better to use RD (remove directory).

RD %systemdrive%\install /S /Q

Also, I'm not sure if you can use it from that batch file, since that batch file is probably in the folder you're trying to delete. If it doesn't work, you can try to add it to the registry (HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce). Then it will run on next logon.

Posted

Okay... :-)

The file is in this folder :-)))) Sorry...

RD %systemdrive%\install /S /Q

is this to be put in my reg. tweak or my sif file???

I'm not sure what you mean :-)

I'm a newbie...or a sort of....

Posted

It depends on what method you use to install.

If you use batch-files, then put the command as the last one (just before the EXIT) command. If you used the MSFN guide to make this, then probably the last part of start.cmd should look like this:

RD /S /Q %systemdrive%\Install

EXIT

Posted

I think I will use the reg way to do it.

But where do i put the code

RD %systemdrive%\install /S /Q

In my reg tweak folder ???

Posted

Add this to a reg file:

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce]
"Cleanup"="cmd.exe /C RD %systemdrive%\install /S /Q"

And then make sure you import it to the registry somewhere. You can also use this code from a batch file:

REG ADD "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce" /V Cleanup /D "cmd.exe /C RD %systemdrive%\install /S /Q"

I believe that should work :)

Posted

I have tryed to run this reg file and restart

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce]

"Cleanup"="cmd.exe /C RD %systemdrive%\install /S /Q"

But the install folder is still there :-((

Posted

Well, the code looks right to me. If the code worked, you should see a command window for a brief moment after you logon. Also, you can make sure that the value was really imported by opening regedit and navigating to the key. Note that if the command was imported and executed, the value is probably gone (you will have to import the reg file again just to see if the value gets added to the registry).

@kenedy: you got a point there, forgot to mention that you might have to use 2 slashes.

Good luck, I'll be back in about 2 hours.

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