1.

Solve : Issues with start command?

Answer» <html><body><p>Im creating a VB program and in that program I create a batch file that...<br/> Code: <a>[Select]</a><a href="https://interviewquestions.tuteehub.com/tag/echo-11626" style="font-weight:bold;" target="_blank" title="Click to know more about ECHO">ECHO</a> off<br/>:loop<br/>echo. C:\Program Files\PeaZip\peazip.exe started at %time% &gt;&gt;server.log<br/>start /wait C:\Program Files\PeaZip\peazip.exe<br/>echo. C:\Program Files\PeaZip\peazip.exe crashed at %time% &gt;&gt;server.log<br/>goto loop<br/>Just using peazip as an example. But basically I want the <a href="https://interviewquestions.tuteehub.com/tag/script-345000" style="font-weight:bold;" target="_blank" title="Click to know more about SCRIPT">SCRIPT</a> to start a server and if it crashes restart it.<br/><br/>Well when I run that script I get the following:<br/><br/><a href="https://img687.imageshack.us/i/84077926.png/"></a><br/>Windows cannot find 'C:\program'. Make sure you typed the name correctly and try again.<br/><br/>Whats happening here?Sorry, I can't see that image (Netfilter... ), can you just write it out?<br/><br/>Pre-post Edit: I see the <a href="https://interviewquestions.tuteehub.com/tag/problem-25530" style="font-weight:bold;" target="_blank" title="Click to know more about PROBLEM">PROBLEM</a> just looking at the code. Paths with spaces need to be enclosed with quotes. So your path <a href="https://interviewquestions.tuteehub.com/tag/would-3285927" style="font-weight:bold;" target="_blank" title="Click to know more about WOULD">WOULD</a> be:<br/>"C:\Program Files\PeaZip\peazip.exe"<br/>Understand?I understand, and I have tried that. However when I put it in quotes it just starts a new DOS with the <a href="https://interviewquestions.tuteehub.com/tag/title-246221" style="font-weight:bold;" target="_blank" title="Click to know more about TITLE">TITLE</a> "C:\Program Files\PeaZip\peazip.exe"OK ignore this post. Quotes put it on the title yes, but if i do:<br/><br/>start /wait "" "C:\Blah Blah\Blah.exe" it works. I just needed a double set of quotes. THanks!</p></body></html>


Discussion

No Comment Found