I've been using the remote tool PSEXEC for a while. Great tool and works great in command line. However I cannot get it to work on button.click in VB.NET
Commandline (works fine)
Psexec \\ComputerName -h -i -s \\FileServer\Share$\ .exe f2C:\psexeclog.txt -f1\\FileServer\Share$\setup.iss
Here's my VB.Net Code
Try
Dim p As New Process()
p.StartInfo.FileName = "C:\path to\PsExec"
p.StartInfo.Arguments = "\\ComputerName -h -i -s \\FileServer\Share$\ .exe f2C:\psexeclog.txt -f1\\FileServer\Share$\setup.iss"
p.Start()
Catch ex As Exception
MessageBox.Show("Could not compete action")
End Try
This connects to the computername fine! The error is when to runs the .exe remotely.
Error: Psexec could not start \FileServer\Share$\ .exe on ComputerName The system cannot find the file specified.
The command line command above works great. Why doesn't the vb.net code ?