Trying to write a windows speech recognition macro. Written using XML and scripting language is JScript. Using ActiveXObject("WScript.Shell"), executables can be, well, executed. But how can we pass an argument to this executable ? Like, if I were to open IE using the above, how can I pass an argument so that it loads with a specified URL(argument) ?
In XML, we could write :
<run command = "C:\Program Files\BlahBlah\MusicPlayer.exe" params = "D:\Music\Music1.mp3"/>
How to do this in JScript ? Or VBScript? Any help appreciated. :)
var ws = ActiveXObject("WScript.Shell");ws.Run('"C:\Program Files\BlahBlah\MusicPlayer.exe" "D:\Music\Music1.mp3"');WScript.Shellreference