Re: Ways to get a Directory Listing in a Text File, or Printed out - Re: Web site directories
- From: "pmj" <post@xxxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 21 May 2007 20:30:07 GMT
"Ali" <ali.on_usenet@xxxxxxxxxxxx> wrote in message
news:Xns9937D618A86D4314159265358@xxxxxxxxxxxxxxxxx
On Mon, 21 May 2007 18:58:37 GMT, pmj commented
"Ali" <ali.on_usenet@xxxxxxxxxxxx> wrote in message
news:Xns9937C1BE28B63314159265358@xxxxxxxxxxxxxxxxx
How do you specify which folder to print the contents of?
Various ways...
Use the CD (Change Directory) Command, in a Command Prompt Window
(or in a Script or Batch File, called up from a windoze Explorer
Window)
That doesn't specify a folder, just changes to the specified folder,
Well, if yo ucall up a Script (or Batch File) by using the *RightClick*
Action, then the Folder Name that yo uRightClick on, is passed to the
Command, (as part of the Command Line) by windoze.
and if I'm going to open a Command Prompt window, I can type
dir D:path\to\folder >dirlist
more easily than cd D:path\to\folder<return>
dir >dirlist
Yep, maybe, but see above.
The idea of doing it from the normal RightClick (Context) Menu,
is that you don't actually have to type anything!...
The Name of (Path to) the Folder (Directory) is passed to the
Comamnd (Batch File/Script) & the actual Command (or series of
Commands to do the Listing/Printing) is in the Batch File/Script.
Or just use Right Click on the Directory (Folder) that you want to
get a Listing of (to Print or Edit or whatever) & the Directory
(Folder) Name will be passed to any Script or Batch File that you
call up from the Context Menu.
Chances are I'll already have that folder open when I decide
I really could do with an editable listing.
Do you mean "Open in (windoze) Explorer?
Or "Open in a Command Prompt Window?
Either way - if you have a windoze Explorer Window Open, you can
use RightClick>SendTo DirPrint (or DirList)
Or - if you have a Comamnd Prompt Window Open, you can use the same
Batch File to do the Listing/Printing, which Saves you the "tedium"/
"Hassle"<g> of Typing the whole Command out, each time you want to
do it.
<snip>Here are some examples, which do basically the same thing as the<snip links>
equivalent Script Folder Action in Apple Mac OS X...
& there are other, easier & quicker ways to get a Directory Listing
- you don't actually need to Faff around Adding "Folder Actions"
&/or Editing the Registry, like those Articles (& lots of similar
Articles on various WebSites) say...
Where the Batch Files are...
DirList.bat
rem Batch File to Create a List of the Contents of a Directory,
rem in a temporary File & Open up that temporary File in Notepad.
@echo off
dir %1 /-p /a /o:gn > "%temp%\DirList.txt"
start /w notepad "%temp%\DirList.txt"
del "%temp%\DirList.txt"
exit
That could be useful, thanks
Yep - they can be *very* useful!!!
But I'm sure a lot of people will have taken one look at it (this
Thread) & turned away (& thus missed out on it)
:-(
Simply cos it contains the word(s) "Batch File" &/or "Script"
& "Command".
:-(
HTH
It did.
& you (& here I do mainly mean you, Ali - cos I know not many other
people use Perl), you can use the same basic principles to call up
a Perl Script/Program (or a JScript or VBScript), from within windoze
Explorer, passing it the Directory or FileName(s) as parameters.
& Perl (& JScript/VBSCript) can do a whole lot more things than
a Plain & Simple Batch File.
Though having said that, the WinXP (& Win2K) Command Interpreter
& Batch Files are very much more capable of all sorts of things
than the original MSDOS Batch Files.
--
pmj
.
- Follow-Ups:
- References:
- Re: Web site directories
- From: Tickettyboo
- Re: Web site directories
- From: Tickettyboo
- Re: Web site directories
- From: Tickettyboo
- Re: Web site directories
- From: ray
- Re: Web site directories
- From: Tickettyboo
- Re: Web site directories
- From: ray
- Re: Web site directories
- From: pmj
- Re: Web site directories
- From: ray
- Re: Web site directories
- From: pmj
- Re: Web site directories
- From: Ali
- Ways to get a Directory Listing in a Text File, or Printed out - Re: Web site directories
- From: pmj
- Re: Ways to get a Directory Listing in a Text File, or Printed out - Re: Web site directories
- From: Ali
- Re: Web site directories
- Prev by Date: Re: Bad websites
- Next by Date: Re: Jerry Atrick's holiday
- Previous by thread: Re: Ways to get a Directory Listing in a Text File, or Printed out - Re: Web site directories
- Next by thread: Re: Ways to get a Directory Listing in a Text File, or Printed out - Re: Web site directories
- Index(es):
Relevant Pages
|