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-12 12:33
中国DOS联盟论坛 » DOS批处理 & 脚本技术(批处理室) » How to clear a copied file and write new content into it View 714 Replies 0
Original Poster Posted 2010-04-16 13:36 ·  中国 湖北 武汉 电信
初级用户
★★
Credits 108
Posts 56
Joined 2007-05-07 16:00
19-year member
UID 87758
Gender Male
Status Offline
sj=Int((100 * Rnd) + 1)
Set fso = Wscript.CreateObject("Scripting.FileSystemObject")
set c=fso.getfile("C:\ip\ip.txt")
w=c.copy("E:\")&sj&(".txt")

No matter how I write the second half, it gives an error. My skills still aren't good enough.

Please help, experts, thanks.
Forum Jump: