Important! This is an automatic machine translated page. If you can read english, you should Click Here to read the original English version of the article.

Add Defragment to the Right-Click Menu for a Drive Lägg Defragmentera till högerklicksmenyn för en enhet

After writing the article last week about how to add Disk Cleanup to the context menu for a drive, I received several requests for how to add another menu item for Defrag instead. Efter att ha skrivit artikeln förra veckan om hur du lägger Diskrensning på snabbmenyn för en enhet, har jag fått flera förfrågningar om hur man lägger ytterligare ett menyalternativ för Defrag istället. With a simple registry hack we can do just that. Med en enkel registren hacka vi kan göra just det.

After manually applying or downloading the hack, you'll have a new item on the right-click menu for your drives… Efter manuellt tillämpar eller hämta hacka, så har du en ny punkt på högerklicksmenyn för dina diskar ...

image

Which will start up the command-line version of Disk Defragmenter (after accepting the UAC prompt) Som kommer att starta command-line version av Diskdefragmenteraren (efter godkännandet UAC snabb)

image

Manual Registry Hack Manuella registren hacka

Open up regedit.exe through the start menu search or run box, and then browse down to the following key: Öppna Regedit.exe upp via Start-menyn sökning eller springa låda och sedan bläddra ner till följande nyckel:

HKEY_CLASSES_ROOT\Drive\shell HKEY_CLASSES_ROOT \ Drive \ shell

image

Create a new key under shell called “runas”, and then set the (Default) value to “Defragment”. Skapa en ny nyckel under skalet kallas "RunAs", och ange sedan (standard) värdet till "Defragmentera". If you want to hide this menu item behind the Shift key right-click menu, then add a new string called Extended with no value. Om du vill dölja här menyalternativet bakom skifttangenten högerklicksmenyn, sedan lägga till en ny sträng som kallas Extended utan värde.

image

Next, you'll need to create a key called “command” and set the default value to the following, which is the command to run defrag with the default options but show verbose output. Därefter måste du skapa en nyckel som kallas "kommando" och fastställa det standardiserade värdet till följande, som är kommandot för att köra defrag med förvalda alternativ men visa utförlig output.

defrag %1 -v defrag% 1-v

You can alternately choose from one of the other defrag switches here if you'd like. Du kan alternativt välja någon av de andra defrag växlar här om du vill.

Downloadable Registry Hack Nedladdningsbara registren hacka

Simply download, extract, and double-click on either AddDefragToDriveMenu.reg (for the regular menu) or AddDefragToExtendedDriveMenu.reg (to hide behind the Shift key). Bara ladda ner, extrahera och dubbelklicka på antingen AddDefragToDriveMenu.reg (för den vanliga menyn) eller AddDefragToExtendedDriveMenu.reg (att gömma sig bakom Skift-tangenten). There's also an included removal script that will remove either one. Det finns också en inkluderad bort skript som tar bort den ena.

Download AddDefragToDriveMenu Registry Hack Hämta AddDefragToDriveMenu registren hacka

This article was originally written on 06/25/08 Tagged with: Denna artikel skrevs ursprungligen på 06/25/08 Märkta med: Vista Tips & Tweaks Vista Tips & tweaks , , Windows 7 Windows 7 , , Windows Vista Windows Vista

Daily Email Updates Dagligt Updates

You can get our how-to articles in your inbox each day for free. Du kan få våra instruktioner artiklar i din inkorg varje dag gratis. Just enter your name and email below: Skriv bara in ditt namn och e-postadress nedan:


Name: Namn:
Email: Email:

Comments (13) Kommentarer (13)

  1. USBman USBman

    As one of those that requested this tweak, I humbly thank you. Som en av dem som begärt detta tweak, jag tackar ödmjukt er.

    Adding the “runas” piece overcame the administrator requirement, and the “Extended” string is a nice touch (works for the aforementioned previous post on adding Disk Cleanup too!). Lägga till "RunAs" Piece övervann administratör krav, och "Extended" strängen är en fin touch (arbeten för ovannämnda föregående inlägg om att lägga Diskrensning också!).

    Overall, the kind of elegant solution I've come to expect from your site. Sammantaget, den typ av eleganta lösningen jag kommit att förvänta sig från din webbplats. Well done. Well done.

  2. The Geek The Geek

    Glad I could help! Glad jag kunde hjälpa! =) =)

  3. Brian Brian

    I sure wanted to try this but without the download. Jag ville se till att prova det här men utan nedladdning.
    Since I have only minimal registry work I was careful to do exactly as you had posted. Eftersom jag har bara minimal registret arbete jag var noga med att göra exakt som du hade postat.

    However, when I select defragmenet I get Men när jag väljer defragmenet jag
    “Which user account do you want to run this program.” "Vilket användarkonto som du vill köra programmet."
    I then selected current user. Jag valde då aktuella användaren.
    But then I get just a flash of the DOS screen and it disappears. Men då får jag bara en blixt av DOS-skärm och den försvinner.

    I have double checked all the registry entries and they look just like the ones you posted. Jag har dubbel kontrollerat all registerposter och de ser precis ut som de du postat. Any idea what I can do to keep the DOS screen from disappearing? Någon aning om vad jag kan göra för att hålla DOS skärmen försvinner?

    BTW, I don't have Vista, I am using XP 2nd Edition. BTW, jag har inte Vista, använder jag XP 2nd Edition.

    THANKS TACK

    BRIAN BRIAN

  4. The Geek The Geek

    @Brian @ Brian

    For XP, you should rename the runas key to something else, like just “defrag”. För XP, ska du byta namn på RunAs nyckeln till något annat, som bara "defrag". I need to update the post to explain the alternate XP instructions… thanks for mentioning. Måste jag uppdatera posten att förklara den alternativa XP instruktioner ... tack för att nämna.

  5. abhs94 abhs94

    Hey Geek, Hey Geek,
    This was really helpful Här var verkligen hjälpsam
    how do you get to know about such tweaks Hur får man veta om sådana tweaks

  6. Mike's beeps! Mike's pip! Hahahahahahahahaha! Hahahahahahahahaha!

    You rock! You rock!

  7. MikeHigham MikeHigham

    You rock! You rock! Thanks! Tack!

  8. Mike Higham Mike Higham

    Could you please do one for Check Disk as well? Skulle ni kunna göra något för Check Disk också?

  9. The Geek The Geek

    @Mike @ Mike

    Will get on that. Kommer att få på den.

  10. Motor Mike Motor Mike

    Does this work for network drives as well? Gör detta åt nätverksenheter också?

  11. brandon brandon

    hey thnx alot for the helpful little tweaks hey thnx mycket för hjälpsamma små tweaks
    greatly appreciated mycket uppskattat

  12. Spacegold Spacegold

    It's a nice little trick and I would jump on it in a second if Vista did not employ automatic defrag every week. Det är ett trevligt litet trick och jag skulle hoppa på den i en sekund om Vista inte har automatisk defrag varje vecka. On the rare occasion when a person might need to defrag a specific disk, it is easily done from the control panel. Vid sällsynta tillfällen då en person kan behöva defragmentera en viss skiva, det är lätt att göra från kontrollpanelen.

  13. bw bw

    I successfully implemented this reg hack, but the CMD prompt closes afterwards (automatically). Jag framgångsrikt genomfört denna reg hacka, men CMD prompten stänger efteråt (automatiskt). Is there a way to have the CMD prompt stay open so I can review the results? Finns det något sätt att få CMD prompt hålla öppet så att jag kan granska resultaten?

    Thanks Geek, not only for a great hack, but a great site. Tack Geek, inte bara för en bra hacka, men en stor tomt.

    bw bw


Leave a Comment Lämna en kommentar




Leave your Lämna ditt friendly friendly comment here. kommentar här.

If you have a computer help question, Om du har en dator hjälp fråga, click here to leave it on the forums Klicka här för att lämna det i forumen instead. istället.

Note: Your comment may not show up immediately on the site. Obs: Din kommentar inte får visa upp omedelbart på platsen.

Our Friends Our Friends
Getting Started Komma igång


About How-To Geek Om How-To Geek
What Is That Process? Hur skall den processen?
svchost.exe svchost.exe
jusched.exe SynTPEnh.exe
dwm.exe dwm.exe
ctfmon.exe CTFMON.EXE
wmpnetwk.exe wmpnetwk.exe
wmpnscfg.exe wmpnscfg.exe
rundll32.exe rundll32.exe
wfcrun32.exe wfcrun32.exe
Ipoint.exe Ipoint.exe
Itype.exe Itype.exe
Wfica32.exe Wfica32.exe
Mobsync.exe Mobsync.exe
conhost.exe conhost.exe
Dpupdchk.exe Dpupdchk.exe Adobe_Updater.exe Adobe_Updater.exe

Copyright © 2006-2009 HowToGeek.com. Copyright © 2006-2009 HowToGeek.com. All Rights Reserved. All Rights Reserved.