Bat File write text file
Posted on 2013-01-21
Hi All -
I am out of my element here ... never worked with .bat files. I am looking for a quick and dirty way to read a directory and create a text file for each file in the directory... trying to avoid having to do this manually....(there's 2000).
Example: I have three documents in my directory: pm1.doc, pm2.doc, pm3.doc. I need the bat file to read thru each one and create a pm1.txt, pm2.txt, and pm2.txt with one line of text inside the text file - the file name (which is variable) and save it in another location on the server.
I'm running this script clientside on Windows XP, but it read and write from folders on the server.
Is there an easy way to do this? Thanks for you help!!