Transper Command Prompt to a File
In this post I want to share how to transfer the result of CMD / MS-DOS (Command prompt) to a file.
Different from previous post
How To copy contents from Command Prompt to Notepad or Ms.Word that
we copy the displayed contents in command prompt then we paste it in a
notepad or word document. In this post we don't need to copy and paste,
because the result will be created in a file directly to a text
(notepad) or doc file.
For example : the command ipconfig, the result will be transferred to the text file.
We insert the character of ">" between command and name of file.
so we have to write :
ipconfig > ip.txt
(the file ip.txt will be created and contain result of ipconfig )
When we need to add other command and we want to put or save the result in the same file (ip.txt), insert two characters of ">>" between command and the file name
example :
ipconfig /all >> ip.txt
Open the result file using notepad