in my JScript HTA script I have a button that executes a CMD command when I press it: <button onclick="callShellApplication('ipconfig')">Your IP-Adress</button>
But this is only one command and I want to execute several. For example @echo hello + ipconfig, I need this because the system on which I execute the command has a CMD block, with the first command it always puts a cryptic character in front of it only with the second command is the command executed. So to get around that I want to execute two commands. How do I do that?
Best regards, jcjms
I will be critiqued for a one line answer rather than adding a full related code block but this is a minor mod from someone else's answer at https://stackoverflow.com/a/70138712/10802527
<button onclick="callShellApplication('cmd /d /c echo/ &ipconfig')">IP-Adress</button>
It is not perfect as it throws the black console widow up for a second before feedback is captured.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.