Several people have suggested using the DIR command. None that I have
seen has suggested using DIR with the /B option, to list only the filenames
and none of the other information included by default.
DIR can also do the sorting for you via the /O option; specifically, /ON
will sort by name.
You probably don't want to include directories, system files, or hidden
files, so you want to use the /A option, specifically /A-RHD.
So the full command is
DIR /B /A-RHD /ON path >file.ext
where "path" is the drive and folder you want to get the content names from,
and "file.ext" is the (path and) name of the file you want the sorted list
to be written to.
David Gillett
On 16 Jul 2003, at 17:31, John Dent wrote:
> Does anyone know how to copy file titles from Windows Explorer so I can
> sort the file titles in Word or Excel etc. I would like to be able to Cut
> and Paste the titles to other programs. (Is there a program that can do it?)
>
> So far this seemingly simple task has no answer.
>
> Thanks
>
> John
>
> Do you want to signoff PCSOFT or just change to
> Digest mode - visit our web site:
> http://freepctech.com/pcsoft.shtml
The NOSPIN Group Promotions is now offering
Mandrake Linux or Red Hat Linux CD sets along
with the OpenOffice CD... at a great price!!!
http://freepctech.com/goodies/promotions.shtml
|