我想使用实时进度条,它会在编写代码或安装某些东西或加载文件时更新。
例子:
@echo off
:main
echo Updating file...
[PROGRESS BAR HERE]
Run Code Online (Sandbox Code Playgroud)
“PROGRESS BAR HERE”表示我想要放置实时进度条的部分。
例如,
@echo off
goto main
:main
echo Select:
echo 1) Goto label 1
echo 2) Goto label 2
set /p choice=
if %choice% == 1 goto label1
if %choice% == 2 goto label2
:label1
echo Will now direct you to label2
echo Press any key to go to label2
pause >nul
:label2 [PROBLEM HERE]
echo Type 'N' or 'E' and press Enter to go back to label1 or exit.
set /p choice2=
if %choice2% == N goto label1
if %choice2% …Run Code Online (Sandbox Code Playgroud) batch-file ×2