Sign in with
Sign up | Sign in
Your question
Closed

full path in directory listing

Last response: in Windows XP
Share
Anonymous
April 24, 2005 11:12:47 AM

Archived from groups: microsoft.public.windowsxp.help_and_support (More info?)

Does Windows XP offer a method to display the full path in a directory
listing? Years ago, from:
dir /s /(some other options) *.qwe

I could get output including the following:
Windows\good\1.qwe
Windows\good\other\111.qwe
Temp\123.qwe
Documents and Settings\gbynum\My Documents\Public\2.qwe

Does this functionality exist using native tools? If not, can anyone
recommend a (prefereably freeware) simple tool to do so?

Thanks!
Anonymous
April 24, 2005 12:26:32 PM

Archived from groups: microsoft.public.windowsxp.help_and_support (More info?)

In news:1114351967.897352.238950@g14g2000cwa.googlegroups.com,
gbynum@att.net <gbynum@att.net> did some thinking and came up with these
words:
> Does Windows XP offer a method to display the full path in a directory
> listing? Years ago, from:
> dir /s /(some other options) *.qwe
>
> I could get output including the following:
> Windows\good\1.qwe
> Windows\good\other\111.qwe
> Temp\123.qwe
> Documents and Settings\gbynum\My Documents\Public\2.qwe
>
> Does this functionality exist using native tools? If not, can anyone
> recommend a (prefereably freeware) simple tool to do so?
>
> Thanks!

Open a command window and type "DIR /?" - without the quotes and you will
see what is available for the DIR command. One possible avenue to achieve
what you desire is the following:
DIR /S *.QWE > c:\search.txt {this directs the output to an edit file on
the C drive for detailed viewing.}

--
Ron Bogart {} ô¿ô¬
Associate Expert
Expert Zone - www.microsoft.com/windowsxp/expertzone
Lovin life on Mercer Island 8^)
"Life is what happens while we are making other plans."
In memory of a true friend, MVP Alex Nichol (1935-2005)
Anonymous
April 25, 2005 2:28:25 AM

Archived from groups: microsoft.public.windowsxp.help_and_support (More info?)

On Sun, 24 Apr 2005 08:26:32 -0700, "Ron Bogart" wrote:

>> Does Windows XP offer a method to display the full path in a directory
>> listing? Years ago, from:
>> dir /s /(some other options) *.qwe
>>
>> I could get output including the following:
>> Windows\good\1.qwe
>> Windows\good\other\111.qwe
>> Temp\123.qwe
>> Documents and Settings\gbynum\My Documents\Public\2.qwe
>>
>> Does this functionality exist using native tools? If not, can anyone
>> recommend a (prefereably freeware) simple tool to do so?
>>
>
>Open a command window and type "DIR /?" - without the quotes and you will
>see what is available for the DIR command. One possible avenue to achieve
>what you desire is the following:
>DIR /S *.QWE > c:\search.txt {this directs the output to an edit file on
>the C drive for detailed viewing.}

Ron, I'm not sure you understood my question. I can, and have, used
the dir /? and tried the documented switches that look promising, to
no avail. If you are telling met here is one that does what I want,
please be so kind as to tell this dumb, stupid fool.

As for the 2nd, redirecting the output to a file ... yeah, you can
redirect the output (and I have), but with over 1200 files meeting my
criteria, and desiring to do some column by column sorting (and having
editors that do that), I still don't have the directory on the line
with the file ... indeed, the directory is listed once for every file
in the directory.

The long and short of it ... thanks for trying, but you didn't address
the question.
Related resources
Anonymous
January 6, 2009 12:58:13 PM

dir /b /s is what you are looking for.
July 30, 2009 6:45:59 PM

Interesting thing is dir commands with both /s /b gives the full path in front of each file on Windows XP System, however if the /b switch is entered without /s switch or /s without /b you will not get the listing with all of the file names shown with full path in front of them. The /s switch displays files in subdirectories as well as in directories. When /s switch is used without /b switch(bare format),the files are arranged in blocks and full path is shown for each of the blocks. When switch /b is used without /s switch the search is done in one folder only; and again they do not have full path displayed in from of each of the files. The combination of the switches gives the required output. This is useful, but prevent new command line users from easily deducing that the combination of the switches would give the required output, with full path in front of each file :pt1cable:  .
May 25, 2010 9:59:46 PM

Interesting. And let me add another question on top of it:
doing dir /b/s gives me the full path for every file in the folder and every subfolder below it. But what if I just want what's in the current folder? Any way to do just that?
March 8, 2011 4:29:37 PM

Command Line "For" statements I often use could be implemented if you're already in the directory you are trying to create a list for. Of course you may redirect the output to a file by appending " >> filename.txt" to the end of the command without the quotation marks.

for /f "tokens=* usebackq" %a in (`dir /b`) do echo %CD%\%a

Roy Hadjinlian
Security+, Network+
March 9, 2011 4:29:54 AM

This topic has been closed by Buwish
!