China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --

Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
DOS stands for freedom, openness and progress. Let us work hard, learn from the openness and GNU spirit of FreeDOS and Linux, and together build and grow a free GNU GPL world!

中国DOS联盟论坛
The time now is 2026-08-13 14:52
中国DOS联盟论坛 » DOS学习入门 & 精彩文章 (教学室) » [Help] About creating a newly created text .bat file View 1,388 Replies 1
Original Poster Posted 2006-12-27 07:05 ·  中国 山东 济南 联通
新手上路
Credits 8
Posts 3
Joined 2006-12-27 06:29
19-year member
UID 74681
Gender Male
Status Offline
I want to write a .bat file with the following requirements:

Create an e:\123.bat
The contents are: [copy]
410$a=225$a
905$f=690$a

I wrote one myself:
copy con e:\123.bat
[copy]
410$a=225$a
905$f=690$a

But I just can't get the result I want.
Could some expert please give me some advice```Thank you :D
Floor 2 Posted 2006-12-27 08:02 ·  中国 湖北 武汉 电信
版主
★★★★★
Credits 11,386
Posts 4,938
Joined 2006-07-23 17:10
20-year member
UID 59080
Status Offline

  copy con e:\123.bat is an interactive process. If you don't use Ctrl+Z and press Enter to confirm the end, then the batch file won't terminate either. If you simply want to write text into it, you can consider commands like echo, type, more, etc.
Forum Jump: