shell execute

Develop and Deploy Native Apps for Windows, OS X, Linux, Unix ...
Post Reply
sedrok
Posts: 26
Joined: Tue Jun 03, 2014 12:50 pm

shell execute

Post by sedrok »

shell execute:
javascript code
var childProcess = require('child_process');
childProcess.exec('wscript.exe C:\\test\\1.vbs',
  function (error, stdout, stderr) {
    xui.echo('stdout: ' + stdout);
    xui.echo('stderr: ' + stderr);
    if (error !== null) {
      xui.echo('exec error: ' + error);
    }
});

Post Reply