06-23-2010, 10:52 AM
Code:
Set oWshShell = CreateObject("wscript.Shell")
sCmd = "nslookup .." 'put your command here
Set oExec = oWshShell.Exec(sCmd)
sStdout = oExec.StdOut.ReadAll
sStdErr = oExec.StdErr.ReadAll
MsgBox "stdout: " & sStdout & " stderr: " & sStderr