• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

How can I print a directory listing in W98 and W2k?

TomBilliodeaux

Senior member
I tried this .bat file in W98.
It prints a blank sheet of paper.

dir %1 /-p /o:gn > "%temp%\Dir Listing"
start /w notepad /p "%temp%\Dir Listing"
del "%temp%\Dir Listing"

Does anyone have a program or .bat file that can print a directory file listings?

Tombilliodeaux@hotmail.com
 
Go to ZDNet and search for TreePrint. Otherwise, just open a DOS prompt, use the dir command and the redirect symbol like you were trying there, and just direct the output to a file:

dir c:\windows > c:\windir.txt
 
There is a free program called FolderPrinter and it's always worked for me in getting a print of my directories.
 
Thanks.
I did download the file "treeprint" which works ok. The output is limited though.
Below is the output of the batch file above, which works great except it will not print. I deleted the line that automatically deletes the .txt file output and this is a partial output that i manually printed:

Volume in drive C has no label
Volume Serial Number is 2E57-14F7
Directory of C:\Download

. <DIR> 08-07-00 6:23a .
.. <DIR> 08-07-00 6:23a ..
ABIT <DIR> 01-08-01 9:01a Abit
ECLIPSE <DIR> 11-30-00 4:02p eclipse
INTEL <DIR> 08-08-00 12:08p Intel
LIMSTEEL <DIR> 08-28-00 10:30a Limsteel
LINUX <DIR> 09-06-00 12:43p Linux
MISC <DIR> 09-14-00 12:23p Misc
SECURI~1 <DIR> 09-12-00 1:44p Securityfiles
TEMP <DIR> 12-06-00 1:03p Temp
UTILIT~1 <DIR> 12-04-00 1:17p Utilities
WIN2K <DIR> 09-11-00 4:35p Win2K
WINDOW~1 <DIR> 08-08-00 10:06a Window98se
744MEU EXE 385,926 10-10-00 4:44p 744meu.exe
ABORTI~1 DOC 23,552 11-06-00 8:04a AbortionDW102K.doc
ACROREAD ZIP 1,344,352 12-18-00 12:19p acroread.zip
AR40ENG EXE 5,455,526 12-18-00 12:57p ar40eng.exe

(actual print is much nicer than is displayed here)
As you can see, the file extensions are displayed in detail on the right where dos uses the ~1. Also the file sizes are included.

I just cannot figure out why the print command does not work thru the batch file.
 
I know from the DOS days there is a command copy FILE LPT1: which would send FILE to LPT1, which regularily is the printer port. Obviously this won't work with USB printers, and I am not sure if it works in 2000.
 
Back
Top