Can cleanmgr.exe be automated?

  • Thread starter Thread starter JD
  • Start date Start date
J

JD

Hi,

Can cleanmgr.exe be automated? It seems that cleanmgr.exe doesn't support
command line options and hence it always pops up a windows requiring me to
specify which drive to be cleaned. If so, it's useless to add it to a batch
file which can then be added as a scheduled task for automation. Any help
is appreciated.

JD
 
In
JD said:
Hi,

Can cleanmgr.exe be automated? It seems that cleanmgr.exe
doesn't support
command line options and hence it always pops up a windows
requiring me to
specify which drive to be cleaned. If so, it's useless to
add it to a batch
file which can then be added as a scheduled task for
automation. Any help
is appreciated.

JD

You use the /sageset switch to configure Disk Cleanup and the
/sagerun switch to run the program. Take a look at these
articles for more info.

How to Automate the Disk Cleanup Tool in Windows XP
http://support.microsoft.com/default.aspx?scid=KB;en-us;315246

Courtesy of Ramesh Srinivasan, MS-MVP
Automate Disk Cleanup using Task Scheduler in Windows XP
http://windowsxp.mvps.org/Automate.htm

Good luck

Nepatsfan
 
Back
Top