View Single Post
  #7  
Old November 5th 17, 01:43 PM posted to microsoft.public.win98.gen_discussion
Lee
External Usenet User
 
Posts: 196
Default Is there a way to turn a folder's filenames into a text file?

On Sunday, November 5, 2017 at 1:19:34 AM UTC-6, R.Wieser wrote:
John,

If you leave out the "C:\\", will it create ADIR.TXT in the directory
whose files it lists?


If it doesn't, try this:

/C DIR %1 /a /o:gne%1\..\ADIR.TXT"


(thats a slash, two dots and a slash)

Regards,
Rudy Wieser


May need:
@="Command.com /C DIR %1 /a /o:gne%1\\..\\ADIR.TXT"

since this is a registry file and two backslashes are needed to equate down to a single backslash for DOS operations - I think.

Looking at the actual value in regedit would show your text as given but the merging of a .reg file causes two backslashes to equal one. I dunno why, just something I've noticed. Sort of like in a batch file when you want %1 done there you need to actually write %%1 when it's done from a batch file only. Again dunno why exactly.

Not remembering all the shortcut scripts but wouldn't that equate to the root drive of the target folder? Something like that is bubbling in the back of my mind anyway.