1

I am trying to send messages to users on my network using Windows msg. If I run it from a VBS, it works fine, but in an HTA, I'm getting error "The system cannot find the file specified".

CreateObject("WScript.Shell").Run "msg /server:myserver username This is the message"

I've also tried

CreateObject("WScript.Shell").Run "cmd.exe /c msg /server:myserver username This is the message"
CreateObject("WScript.Shell").Run "C:\Windows\System32\msg.exe /server:myserver username This is the message"

I've tried running it without /server as well

I should also mention that I added a Pause in the cmd prompt to see the error, and I'm getting the following:

'msg' is not recognized as an internal or external command
Cameron Darlington
  • 355
  • 2
  • 7
  • 14

0 Answers0