Disk Cleanup : Extended

Page 1 of 10 123 ... LastLast
    Disk Cleanup : Extended

    Disk Cleanup : Extended

    How to Use Extended Disk Cleanup in Vista, Windows 7, and Windows 8
    Published by
    Designer Media Ltd


    How to Use Extended Disk Cleanup in Vista, Windows 7, and Windows 8

    This will show you how to access and run the Extended Disk Cleanup function in Windows, allowing you to clean up more HDD space for you to use.

       Note

    This must be done in an elevated command window to complete.



    Let's get started!

    1) In the Windows 7 start menu search box type "cmd" (without the quotes) right click the entry and select "Run As Administrator" then enter your user credentials for the UAC prompt and click yes to open the command window.
    Disk Cleanup : Extended-cmd-runas.jpg
    Disk Cleanup : Extended-cmd-uac.jpg
    2) In the command window that opens type the command below and hit enter.

    Be advised: the command window must be left open while the cleanup is carried out.

    Code:
    %SystemRoot%\System32\Cmd.exe /c Cleanmgr /sageset:65535 & Cleanmgr /sagerun:65535

    Disk Cleanup : Extended-cmd-text.jpg

    3) Now you will see the Disk Cleanup Settings window with more options available to you, select the ones you want to clean up then click ok; wait for the search and then the cleanup and then you're done.
    Disk Cleanup : Extended-disk-cleanup.jpg
    Disk Cleanup : Extended-checking.jpg
    Disk Cleanup : Extended-cleaning.jpg
    To add a shortcut to the desktop.

       Note

    This .bat file was created by CarlTR6 credit for this goes to him!


    1) In the Windows start menu search box type "notepad" (without the quotes) right click the entry and choose Run as Administrator then enter your user credentials in the UAC prompt and click yes to open notepad.
    Disk Cleanup : Extended-notepad-runas.jpg
    Disk Cleanup : Extended-uac-notepad.jpg
    2) In notepad type the code below then in the upper left of notepad at File select "Save as" name the file anything you want but it must have the .bat extension then browse to C:/Windows/System32 and click Save, then back at "File" click "Exit" to close notepad.
    Code:
     cd C:\windows\system32 
    %SystemRoot%\System32\Cmd.exe /c Cleanmgr /sageset:65535 & Cleanmgr /sagerun:65535
    Disk Cleanup : Extended-carls.jpg
    Disk Cleanup : Extended-carls1.jpg
    Disk Cleanup : Extended-carls2.jpg
    3) Now click an empty spot on the desktop and click, "New, Shortcut" in the "Create Shortcut" window browse to C:\Windows\System32\<your file name.bat> and click ok, then in the next window click next, then for the last "Choose Name" window name the shortcut whatever you want (I chose something clever, "Clean") then click "Finish" to add the shortcut to the desktop, you're done.
    Disk Cleanup : Extended-carls6.jpg
    Disk Cleanup : Extended-carls7.jpg
    Disk Cleanup : Extended-carls8.jpg
    Disk Cleanup : Extended-name.jpg
    Disk Cleanup : Extended-clean.jpg
    Enjoy! :)






  1. Posts : 11,990
    Windows 7 Ultimate 32 bit
       #1

    Thanks BFK; it worked well. I need to create a batch file for this.
      My Computer


  2. Posts : 22,814
    W 7 64-bit Ultimate
    Thread Starter
       #2

    Thanks Carl, if you want to post the .bat for others, feel free.
      My Computer


  3. Posts : 11,990
    Windows 7 Ultimate 32 bit
       #3

    I created the batch file in Notepad and named it clean.bat. The name does not matter; you can name it anything you wish as long as you give it the .bat extension.

    Open Notepad. copy and paste the two lines below into Notepad.

    cd C:\windows\system32
    %SystemRoot%\System32\Cmd.exe /c Cleanmgr /sageset:65535 & Cleanmgr /sagerun:65535

    Click on File and select Save as...

    Type the file name and give it the .bat extension.

    Select All files (*.*) and click Save.

    Once I saved the file I moved it from the Documents folder to the Windows> System32 folder. The path on my computer is C:\Windows\System32.

    To run the batch file and the program, open cmd as an administrator and type "clean" or whatever you named the file (without the quotation marks) at the prompt and hit Enter.
    Last edited by CarlTR6; 05 Apr 2010 at 20:37. Reason: Corrected a typing error.
      My Computer


  4. Posts : 22,814
    W 7 64-bit Ultimate
    Thread Starter
       #4

    Cool, thanks Carl.
      My Computer


  5. Posts : 11,990
    Windows 7 Ultimate 32 bit
       #5

    You are welcome. I hope it helps someone.
      My Computer


  6. Posts : 3,427
    Windows 10 Pro x64
       #6

    carl and BFK great work, i would rep you, but apparently i havent repped enough people yet to make it work

    carl i think your batch file is slightly wrong, i get "the filename directory name or volume syntax is incorrect" it still works because it has defaulted to C:\windows\system 32 anyway but on the first line, rather than "cd\C:\windows\system 32" shouldnt it be "cd c:\windows\system 32 (with a space instead of the slash)
      My Computer


  7. Posts : 17,322
    Win 10 Pro x64
       #7

    Thanks Ted and Carl, Nice Work!
    +rep For both of you.
    Derek

    Thanks severedsolo also for spotting that.

    The new one works perfect Carl.
    Last edited by derekimo; 05 Apr 2010 at 20:48. Reason: updated
      My Computer


  8. Posts : 11,990
    Windows 7 Ultimate 32 bit
       #8

    Yes, it should. That is a mistype on my part. I will correct it. Thank you very much.
      My Computer


  9. Posts : 11,990
    Windows 7 Ultimate 32 bit
       #9

    Thank you Derek. Much appreciated.
      My Computer


 
Page 1 of 10 123 ... LastLast

  Related Discussions
Our Sites
Site Links
About Us
Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 04:13.
Find Us