我想在不提示的情况下停止服务。这是我尝试过的:
C:\>echo y|net stop WAS
The following services are dependent on the Windows Process Activation Service service.
Stopping the Windows Process Activation Service service will also stop these services.
World Wide Web Publishing Service
Do you want to continue this operation? (Y/N) [N]:
No valid response was provided.
我想在批处理作业中完成此操作。
答案1
有一个未记录的net
与命令一起使用的参数,/y
或者/yes
绕过提示。因此,对于您的情况,它将是:
net stop WAS /y