This article describes how to add  the Print Directory option in the context menu of file system folders in Windows Vista. Adding this option helps you quickly send the directory listing to the printer or a file.

Adding the "Print Directory" feature

  • Click Start, type Notepad. When Notepad appears in the Start menu search results, right-click and choose Run as Administrator
  • Copy the following text to Notepad:
@echo off
dir %1 /-p /o:gn > "%temp%\Listing"
start /w notepad /p "%temp%\Listing"
del "%temp%\Listing"
  • Click File, Save (CTRL+S), mention the file name/path as %windir%\printdir.bat and press ENTER. The file printdir.bat is now saved to the Windows folder.
  • Download printdir_vista.reg from the Attachments section of this article.
  • Save printdir_vista.reg to Desktop, right-click the file and choose Merge. If you are prompted for an administrator password or confirmation, type the password or provide confirmation.
Tip: If you want to only view the file contents, and don't want to send it to the printer, alter the 3rd line in the Printdir.bat above, so that the following command:
start /w notepad /p "%temp%\Listing"

start /w notepad "%temp%\Listing"

The Print Directory option is now added to the context menu of file system folders in your Windows Vista computer.