开发者

how to read from a file in batch?

开发者 https://www.devze.com 2022-12-15 01:52 出处:网络
how to read from a file in batch and set it as variable under MSDos 6.22 (windows 3.11) i have tried set /p var= < text.开发者_如何学运维txt

how to read from a file in batch and set it as variable under MSDos 6.22 (windows 3.11) i have tried

set /p var= < text.开发者_如何学运维txt

have also tried

for /f %%a in (text.txt) do (command)

both is work only in windows xp, can anybody suggest in windows 3.11?


Reading Text Files into MS-DOS Environment Variables

Applies to: ... Microsoft MS-DOS 6.22 Standard Edition

So the environment variable becomes an intermediary step so you can get the contents from a text file to a variable in some batch file.

0

精彩评论

暂无评论...
验证码 换一张
取 消