Pular para o conteúdo principal

How to Create a Shortcut That Nukes Every Running Windows App

How to Create a Shortcut That Nukes Every Running Windows App: "
image

Have you ever had dozens of application windows open and wanted to just close them all? There’s a bunch of freeware apps that will close them all for you, but you don’t need extra software—and here’s how to do it.

What we’ll do is use the taskkill command with a bunch of custom arguments that specify to kill everything other than Explorer—but you can really customize it to anything you’d like, and keep in mind you should really read this carefully before proceeding.

Create the Nuke Everything Command


The first thing you’ll want to do is open up a command prompt and then type taskkill /? so you can see the syntax. Loads of options!

sshot-2010-10-21-[12]

We’ll be using a couple of operators to accomplish what we want, including these two:

  • /F – force closes the applications (this is optional, keep in mind force closing will lose unsaved data)
  • /FI – uses a filter, which is where the magic is

The filter command takes a set of arguments, which you can see in the help, but we’ll put them here as well:




Filters:
Filter Name   Valid Operators           Valid Value(s)
-----------   ---------------           -------------------------
STATUS        eq, ne                    RUNNING |
NOT RESPONDING | UNKNOWN
IMAGENAME     eq, ne                    Image name
PID           eq, ne, gt, lt, ge, le    PID value
SESSION       eq, ne, gt, lt, ge, le    Session number.
CPUTIME       eq, ne, gt, lt, ge, le    CPU time in the format
of hh:mm:ss.
hh - hours,
mm - minutes, ss - seconds
MEMUSAGE      eq, ne, gt, lt, ge, le    Memory usage in KB
USERNAME      eq, ne                    User name in [domain\]user
format
MODULES       eq, ne                    DLL name
SERVICES      eq, ne                    Service name
WINDOWTITLE   eq, ne                    Window title

NOTE
----
1) Wildcard '*' for /IM switch is accepted only when a filter is applied.
2) Termination of remote processes will always be done forcefully (/F).
3) 'WINDOWTITLE' and 'STATUS' filters are not considered when a remote
machine is specified.


Now that we’ve seen the possible arguments for the filters, it’s time to put them together. For example, if you wanted to kill every app by your username, you’d use taskkill like this to check where your username is “eq” (equal) to geek.

taskkill /F /FI 'USERNAME eq geek'

The only problem with this is that it would also kill explorer.exe and dwm.exe, so your whole screen would flash and the Start Menu would completely disappear—probably not what you want. Thankfully we can chain together multiple instances of the /FI argument to fix this problem, and we’ll use the IMAGENAME, which is the name of the executable, and the “ne” for “Not Equal” to the ones we don’t want to kill.

taskkill /F /FI 'USERNAME eq geek' /FI 'IMAGENAME ne explorer.exe' /FI 'IMAGENAME ne dwm.exe'

You can customize this even further if you’d like, adding extra processes that you don’t want to close into the list. It’s really up to you—just keep in mind that if you accidentally kill Explorer.exe you can always use Ctrl+Shift+Esc to open Task Manager, and restart the process from the File –> Run menu.

Note: if you don’t want to force kill the applications, you should remove the /F argument.

Create the Nuke Windows Shortcut


Once you’ve got the command figured out, it’s easy enough to create the shortcut—just right-click anywhere and choose New Shortcut. Once you’re there, drop the full command into the location box.

image

Give it an icon and put the shortcut somewhere, and you’re all done. Now you can kill everything in one shortcut, with no added software!

image

In case you’re wondering, you can find this icon in the Windows\System32\imageres.dll file.



Note: use of this shortcut should be done at your own risk, and if your computer explodes don’t blame us. We warned you.
"

Comentários

Postagens mais visitadas deste blog

Favigen, Favicon Generator

Favigen, Favicon Generator : " Favicons are small icons that help identify websites. They are used as a visual representation of a website both in the web browser and at many online services. The three most prominent locations of favicons are the browser’s address bar, the tabbar and the bookmarks folder. Many webmasters like to create custom favicons to add that custom identifier to their website. Favicons can be created in many image and icon editors, but also online. Favigen is a straightforward favicon generator that can turn an image into a favicon. All that it takes is to pick an image from the local hard drive first, select the dimensions of the favicon and click the submit button to make the service generate the favicon. Favigen supports several image formats, including jpg and png, and it does not seem to have size restrictions either. Available image dimensions range are 16×16, 32×32 and 64×64. The generated favicon is displayed directly on the page. A click on do...

A simple rsync script to back up your home directory

A simple rsync script to back up your home directory : " Backing up important data is obviously something we should all do. Unfortunately, it is not always easy to make it happen. We get lazy; we do not have the additional hardware for a backup server; it takes a long time and a lot of CDs to back up to optical media; we do not trust online backup services; backup schemes are difficult to set up and use — any of dozens of reasons can stand in our way. Still, we know we should be backing up our important data. Modern open source Unix-like operating systems offer a plethora of options for incredibly simple, effective backup schemes, however. If the problem is figuring out how to set one up, a simple rsync solution may be exactly what you need. The rsync utility is used to synchronize files between two systems. It does so by way of incremental copies, only copying from the source to the destination what has not already been copied there, saving time, network bandwidth, and syst...

Google Wave now open to the public: faster, Robots and Gadgets aplenty!

Google Wave now open to the public: faster, Robots and Gadgets aplenty! : " Filed under: Internet , Google If you somehow missed it, Google Wave is now a bonafide Labs project: rather than being an invite-only alpha, it's now a public beta test! If you don't already have an account, just head on over to Wave and use your regular Google login details. If you've not seen any of the Google Wave introductory videos , you should check them out -- they explain the whole thing a lot more succinctly than I ever could. Wave has also been enabled for Google Apps domains -- businesses could convert their internal communication to Waves today! Leading up to this public release there have a lot of changes. It's by no means finished, but Google Wave is now a lot faster . It's also more intuitive -- more useful -- and given the large number of Robots and Gadgets now reaching prime-time readiness, it feels like the mass adoption of Wave is imminent. Also, if you're an ol...