"George Hester" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> OK here we go. Without a bat file:
>
> D:\DVDs\(for /R "h::\" %i in (*.*) do @echo %~nxi) > BIBLE1.txt
>
> where h: is the CD-ROM drive. Thanks.
>
In a batch file the % used to note for variables (e.g., %a, %i)
must be doubled (e.g., %%a, %%i).
It's a quirk of the command line versus batch file parsing.
--
Herb Martin, MCSE, MVP
Accelerated MCSE
http://www.LearnQuick.Com
[phone number on web site]
> --
>
> George Hester
> _________________________________
> "Alexander Suhovey" <(E-Mail Removed)> wrote in message
> news:00df01c71240$7f1f8ed0$(E-Mail Removed)...
>> > -----Original Message-----
>> > From: George Hester [private.php?do=newpm&u=]
>> > Posted At: Monday, November 27, 2006 5:30 PM
>> > Posted To: microsoft.public.win2000.cmdprompt.admin
>> > Conversation: dir without path?
>> > Subject: dir without path?
>> >
>> > I need to use the dir command to get a listing of files off the
>> CD-ROM. But
>> > I do not what the path in the names of the files.
>>
>> George,
>>
>> Try this:
>>
>> for /r "e:\" %i in (*.*) do @echo %~nxi
>>
>> where e:\ is your CD/DVD drive letter. When used in batch scripts,
>> double percent signs (%%i instead of %i).
>>
>> --
>> Alexander Suhovey
>>
>
>