Copying CMD.exe using batch file?

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
reptilemikael
Posts: 1
Joined: 08 Mar 2019 12:22

Copying CMD.exe using batch file?

#1 Post by reptilemikael » 08 Mar 2019 12:28

is it possible to create a batch file to copy a open command prompt text? if so how? if not is there a different way?

aGerman
Expert
Posts: 3605
Joined: 22 Jan 2010 18:01
Location: Germany

Re: Copying CMD.exe using batch file?

#2 Post by aGerman » 10 Mar 2019 06:23

There is no command to copy the content of a console window programmatically. Right click on the title bar, Edit->Select all, then hit Enter to copy the content into the clipboard.

It would be possible to write a tool in another language to copy the content of the window from where the tool was called (EDIT okay, just wrote one https://sourceforge.net/projects/concpy/). But it wouldn't be reasonable to try to copy something out of a foreign window.

Steffen

Post Reply