最佳答案
在 DOS 批处理文件中我们只能有一行 if 语句正文?我想我找到了一个地方,我可以使用 ()
作为 if 块,就像在类 C 编程语言中使用的 {}
一样,但是当我尝试这样做时,它并没有执行语句。也没有错误消息。这是我的原则:
if %GPMANAGER_FOUND%==true(echo GP Manager is up
goto Continue7
)
echo GP Manager is down
:Continue7
奇怪的是,当我运行批处理文件时,既没有打印“ GP 管理器已经启动”,也没有打印“ GP 管理器已经启动”。