![]() |
China DOS Union-- Unite DOS · Advance DOS · Grow DOS --Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum |
| Guest | Log in | Register | Members | Search | China DOS Union |
|
中国DOS联盟论坛 The time now is 2026-08-12 10:16 |
47,811 topics / 349,897 posts / today 0 new / 48,256 members |
| DOS学习入门 & 精彩文章 (教学室) » 【Help】How to create a TXT file under DOS |
| Printable Version 1,831 / 5 |
| Floor1 explor | Posted 2010-10-07 22:41 |
| 初级用户 Posts 14 Credits 30 | |
|
How to create a TXT file under DOS
|
|
| Floor2 HAT | Posted 2010-10-07 23:30 |
| 版主 Posts 5,017 Credits 9,023 | |
| Floor3 sytyh | Posted 2010-10-08 15:51 |
| 新手上路 Posts 9 Credits 21 | |
|
First line command: copy con new.txt
Second line: Enter your text Last line end command: ctrl+Z |
|
| Floor4 explor | Posted 2010-10-08 18:38 |
| 初级用户 Posts 14 Credits 30 | |
|
Thanks to the moderator. But after running this command, the file content is CN-DOS. How to make this file empty?
|
|
| Floor5 explor | Posted 2010-10-08 18:41 |
| 初级用户 Posts 14 Credits 30 | |
Originally posted by sytyh at 2010-10-8 15:51: Test passed, thanks a lot! |
|
| Floor6 explor | Posted 2010-10-08 18:52 |
| 初级用户 Posts 14 Credits 30 | |
|
Just learned, for everyone's reference and study:
There are two usages of copy con. 1. Create a new file copy con filename After entering this command and pressing Enter, you enter the editing state. Enter the required content on the screen. After entering, press <Ctrl>+Z to end the editing, and the system automatically saves it. This command can be used for simple text editing, but it can only create new files. If there is a file with the same name in the current specified path, it will be overwritten (if you want to edit the old file, please use EDIT). 2. Display file content (equivalent to TYPE) copy filename con Then the content of the specified file will be displayed on the screen. In DOS, some devices appear in the form of special file names, such as CON (screen), PRN (printer), etc. They can be used in combination with COPY and other commands to complete many special tasks. |
|
|
[ Contact the Union admin team -
中国DOS联盟 -
Standard version ] Sponsored by ifanr Inc | © 2001–2023 |