How to Determine the Number of Files on a Drive
- 1). Click the "Start" button on the Windows taskbar.
- 2). Type "cmd" without the quotes in the "Start Search" textbox. The command prompt window will open.
- 3). Type "cd/" without the quotes, and press the "Enter" key. You will see the C:\ prompt. If you want to find out the number of files on the C: drive then this is where you want to be to enter the other commands. If you want to see the files on another drive then type in the drive letter, followed by a colon to get to the drive prompt. For example, to get to the D: drive, type "d:" without the quotes and press the "Enter" key.
- 4). Type "dir /s" without the quotes and press the "Enter" key. Dir is the directory command. The /s tells the directory command to look in all subdirectories while it performs its search. When the search is finished you will see the total number of files and directories on the hard drive. Directories are now known as folders. The search performed does not show the hidden files on the drive.
- 5). Write down the number of files found by the dir /s command.
- 6). Type "dir /s /ah" without the quotes and press the "Enter" key. This command has added the /ah switch, which looks for and displays files with the hidden attribute.
- 7). Add the number of files found using the dir /s command with the number of files found with the dir /s /ah command. This is the total number of files on your hard drive.
Source...