How to convert file name into text file

Asked By 50 points N/A Posted on -

I know the title may confuse you.

What I want is to be able to obtain a text file that would contain all the file names from a directory.

I don't know how to explain better but I think you guys understand what I mean.

A solution to convert file name into text file in a simple way.

Someone told me I could have done this in Linux, but I am using Windows 7 so perhaps you here at Techyv have a proper solution for me.

Answered By 0 points N/A #176629

How to convert file name into text file


Here is how you go about,

DIR /s >filename.txt


will provide you with all the filenames of all internet directories are supposed to be the present listing. Keep in mind that this implies that if you are at the DOS immediate and the immediate says something like C:WINDOWS> you only get the details from the windows listing. You'll have to kind CD to get returning to the main.


The details will all be published to the computer file with all kinds of headlines and bottom details for each listing seperatedly. If you don't want that, add the /b switch:


DIR /s /b >Filename.txt


Please observe that now the whole filepath of each computer file is also shown.


It is also keep in mind in all WinNT like OSs, you only get the brief filename in the old MS-DOS 8.3 structure. Based on what you want to do, that may or may not be useful.


In Win9x editions however, you only get the lengthy windows design filename. This distinction has already triggered me enormous disasters, as it creates set details or applications using seashells to DOS absolutely mismatched for different editions of Windows. For those that use Win9x, you can get the brief filenames by including the undocumented /z change. Keep in mind however that it isn't reinforced by WinNT like OSs, and that contains XP.

Login/Register to Answer

Related Questions