O código é o seguinte: função sono (n) { var a = new ActivexObject ("wscript.shell"); a.run ("% CONSPEC% /c ping -n" + n + "127.0.0.1> nul", 0, 1); a = nulo; }