All Posts Tagged With: "prompt"

Running A Command Prompt As Administrator (Vista or 7)

Certain commands in Windows Vista and 7 require “elevation” in order to execute. For example, if you run NETSTAT -B, a notice will appear that states:

The requested operation requires elevation.

What does this mean exactly? It’s means you need additional permission(s) to execute the operation. This is done by executing a Command Prompt as Administrator. See video below for instructions on how to do it (it’s easy).

Fear Not The Command Prompt, File Listings (Windows XP)

imageHere are a few quick tips you can do from the command prompt in Windows XP (this will actually work in all versions of Windows since 3.1):

Getting a listing of every single frickin’ thing on your hard drive in a single text file

Command:

DIR /S C:\*.* > C:\all.txt

This will write a text file of every single file on your system (excluding hidden files) to the file all.txt in the root of C drive. It will take a while and the text file will be humongous. When I did this my end result text file was 9MB in size. For a text file, that’s huge.

If you try to open this file afterwards in Notepad, it will crash because Notepad can’t handle something this big. However, if you get a better text editor like Notepad++, you can open big honkin’ text files.

Reason why would you would want to to this: There is no easier way to get a complete listing of all files in Windows in a portable file. If you’re troubleshooting your computer and want to see where specific stuff is without clicking all over the place, this is the way to do it. And it’s unbelievably faster than listing files using the standard Windows search.

Getting a listing of a specific type of file using the same method

Command:

DIR /S C:\*.DOC > C:\alldocs.txt

This will write a text file called alldocs.txt to the root of C drive containing a listing of every single file on your system ending with DOC (i.e. Word documents).

Since this listing will be much smaller it can be opened in Notepad easily. Launch Notepad and open the file C:\alldocs.txt and you’re off to the races.

You can do this with any file extension. If you want to find all XLS (Excel) files, change *.DOC to *.XLS. If you want to find all JPG files, change *.DOC to *.JPG – you get the idea.

Common file extensions in Windows

  • Plain Text: TXT
  • Word: DOC
  • Excel: XLS
  • Video: AVI, WMV, MPG, MPEG, QT, MOV
  • Audio: WMA, MP3
  • Image: JPG, JPEG, GIF, PNG
  • Archive: ZIP, RAR
  • Executable file/installer: EXE, MSI