Print directory listing to network printer.

esevin

New member
Local time
6:45 AM
Messages
4
I've installed MS's printdir.bat file but it's not working properly. When I select Print Directory Listing from the context menu in Windows Explorer, I can see a background flash that indicates the file is executing, but nothing gets to the printer. When I execute PrintDir.bat from the command line, the C:\Windows directory tree prints from the default network printer. I think my problem relates to the presence of the network printer that isn't called out properly in the batch file. (I have 2 network printers). Appreciate any help. Thanks,

Gene
 

My Computer My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Home brew
OS
Windows 7 Pro 64-bit
Hello Gene, and welcome to Seven Forums.

If you like, see if using OPTION ONE in the tutorial below may work better for you. It prints to your default printer by default.

Context Menu - Add View and Print File Directory

Hope this helps, :)
Shawn
 

My Computer My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Self built custom
OS
64-bit Windows 11 Pro for Workstations
CPU
Intel i7-8700K OC'd to 5 GHz
Motherboard
ASUS ROG Maximus XI Formula Z390
Memory
64 GB (4x16GB) G.SKILL TridentZ RGB DDR4 3600 MHz
Graphics Card(s)
ASUS ROG-STRIX-GTX1080TI-O11G-GAMING
Sound Card
Integrated
Monitor(s) Displays
2 x Samsung Odyssey G7 27"
Screen Resolution
2560x1440
Hard Drives
1TB Samsung 990 PRO M.2,
4TB Samsung 990 PRO PRO M.2,
TerraMaster F8 SSD Plus NAS
PSU
Seasonic Prime Titanium 850W
Case
Thermaltake Core P3
Cooling
Corsair Hydro H115i
Keyboard
Logitech wireless K800
Mouse
Logitech MX Master 4
Internet Speed
2 Gb/s Download and 100 Mb/s Upload
Antivirus
Malwarebyte Anti-Malware Premium
Browser
Google Chrome
Other Info
Logitech Z625 speaker system,
Logitech BRIO 4K Pro webcam,
HP Color LaserJet Pro MFP M477fdn,
APC SMART-UPS RT 1000 XL - SURT1000XLI,
Galaxy S23 Plus phone
: Print directory listing to network printer - Solution

The suggested solution was a 50% winner, but that's good enough. I was provided with 2 batch files: (1) to add "Print Directory Listing" to Explorer's context menu, and (2) to add "View Directory Listing" to the menu. The first worked the same as my original; that is, it seemed to work but didn't print; the 2nd opened up Notebook with a listing of the directory, from which I was able to print. I still don't understand why the Printdir.bat doesn't work as advertised, but I'll leave that for another day. Meanwhile, I very much appreciative of the quick response for a practical solution to my problem.

Gene
 

My Computer My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Home brew
OS
Windows 7 Pro 64-bit
A couple of things to check so far.

Are you using the context menu to execute the .bat from?

Is the network printer set as the default printer?
 

My Computer My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Self built custom
OS
64-bit Windows 11 Pro for Workstations
CPU
Intel i7-8700K OC'd to 5 GHz
Motherboard
ASUS ROG Maximus XI Formula Z390
Memory
64 GB (4x16GB) G.SKILL TridentZ RGB DDR4 3600 MHz
Graphics Card(s)
ASUS ROG-STRIX-GTX1080TI-O11G-GAMING
Sound Card
Integrated
Monitor(s) Displays
2 x Samsung Odyssey G7 27"
Screen Resolution
2560x1440
Hard Drives
1TB Samsung 990 PRO M.2,
4TB Samsung 990 PRO PRO M.2,
TerraMaster F8 SSD Plus NAS
PSU
Seasonic Prime Titanium 850W
Case
Thermaltake Core P3
Cooling
Corsair Hydro H115i
Keyboard
Logitech wireless K800
Mouse
Logitech MX Master 4
Internet Speed
2 Gb/s Download and 100 Mb/s Upload
Antivirus
Malwarebyte Anti-Malware Premium
Browser
Google Chrome
Other Info
Logitech Z625 speaker system,
Logitech BRIO 4K Pro webcam,
HP Color LaserJet Pro MFP M477fdn,
APC SMART-UPS RT 1000 XL - SURT1000XLI,
Galaxy S23 Plus phone
: Print directory listing to network printer

A couple of things to check so far.

Are you using the context menu to execute the .bat from?

Is the network printer set as the default printer?

I don't understand the first question. The registry was modified appropriately so that the Print Directory Listing is selected from the context menu by right-clicking on a folder in Windows explorer.

As to the second question: yes, the network printer is the default printer.

I think the problem lies in the fact that the Printdir.bat file doesn't properly identify the default printer. However, as I've already posted, the Viewdir.bat file properly displays the folder listing in Notebook from which it's possible to print.
 

My Computer My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Home brew
OS
Windows 7 Pro 64-bit
Yep, that's what I was asking if you were using the context menu, and not just running the .bat directly.

The Printdir.bat basically does the same as the Viewdir.bat file, but uses the /p switch to print the directory list to the default printer instead of copying it to a .txt file.

I'm not sure why it doesn't print. :confused:
 

My Computer My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Self built custom
OS
64-bit Windows 11 Pro for Workstations
CPU
Intel i7-8700K OC'd to 5 GHz
Motherboard
ASUS ROG Maximus XI Formula Z390
Memory
64 GB (4x16GB) G.SKILL TridentZ RGB DDR4 3600 MHz
Graphics Card(s)
ASUS ROG-STRIX-GTX1080TI-O11G-GAMING
Sound Card
Integrated
Monitor(s) Displays
2 x Samsung Odyssey G7 27"
Screen Resolution
2560x1440
Hard Drives
1TB Samsung 990 PRO M.2,
4TB Samsung 990 PRO PRO M.2,
TerraMaster F8 SSD Plus NAS
PSU
Seasonic Prime Titanium 850W
Case
Thermaltake Core P3
Cooling
Corsair Hydro H115i
Keyboard
Logitech wireless K800
Mouse
Logitech MX Master 4
Internet Speed
2 Gb/s Download and 100 Mb/s Upload
Antivirus
Malwarebyte Anti-Malware Premium
Browser
Google Chrome
Other Info
Logitech Z625 speaker system,
Logitech BRIO 4K Pro webcam,
HP Color LaserJet Pro MFP M477fdn,
APC SMART-UPS RT 1000 XL - SURT1000XLI,
Galaxy S23 Plus phone
: Print directory listing to network printer

That makes two of us.
 

My Computer My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Home brew
OS
Windows 7 Pro 64-bit
Back
Top