Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/batch-file/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Batch file 在弹出窗口中回答问题_Batch File - Fatal编程技术网

Batch file 在弹出窗口中回答问题

Batch file 在弹出窗口中回答问题,batch-file,Batch File,我有一个批处理文件,我想用它来退出.exe文件。exe正在运行,但它会弹出一个需要一些信息的窗口。如何在弹出窗口中输入正确的信息?servername.domain是需要放在弹出窗口中的服务器地址。我认为这是填充弹出窗口的语法,但它不起作用。任何帮助都会很好 SetupCodeGroup.exe servername.domain 我发现你不能用批处理文件做你想做的事情。当我遇到simaler问题时,我使用了vbscript sendkeys方法。如果你用谷歌搜索,你应该可以做你想做的事 对于

我有一个批处理文件,我想用它来退出.exe文件。exe正在运行,但它会弹出一个需要一些信息的窗口。如何在弹出窗口中输入正确的信息?servername.domain是需要放在弹出窗口中的服务器地址。我认为这是填充弹出窗口的语法,但它不起作用。任何帮助都会很好

SetupCodeGroup.exe servername.domain

我发现你不能用批处理文件做你想做的事情。当我遇到simaler问题时,我使用了vbscript sendkeys方法。如果你用谷歌搜索,你应该可以做你想做的事

对于你的情况,我会有一个批处理文件作为bass来运行你编写的vbscrit程序来填充.exe中的信息

像这样的一批货 (如果您复制并通过了此操作,请务必删除注释(//))


我希望这能有所帮助。

哇!没有人知道我做错了什么?
@echo off
set reapet=100   // just setting varibles to be used in the delay loop
set con=1
set time=0

start (your .exe)  //starts your EXE

:begin
set /a time=%time%+%con%
if %time%==%reapet% goto:startvb        // this makes a delay so that we can be sure your     
goto:begin                              // computer fully started the .exe :)

:startvb
cls
start your (vbscript)               // this starts your vbscript

cls
echo Done                           // tells you the batch file is done
pause