Tuesday, 15 May 2012

vb.net - psexec with vb cannot find specified file -



vb.net - psexec with vb cannot find specified file -

i made little programme launches .exe on remote computer. when run psexec cmd prompt, works fine, when run in vb errors with, "cannot find file specified".

dim targetpc string = "192.168.1.3" seek dim p new process() p.startinfo.filename = "c:\users\johndoe\desktop\pstools\psexec.exe" p.startinfo.arguments = "\\" & targetpc & " " & "c:\program files (x86)\avs4you\avsaudioconverter\avsaudioconverter.exe" p.start() p.waitforexit() grab ex exception msgbox("shit didnt work") end seek

is concat string correct? missing here.

i able solve below:

p.startinfo.arguments = "\\" & targetpc & " " & chr(34) & "c:\program files (x86)\avs4you\avsaudioconverter\avsaudioconverter.exe" & chr(34)

vb.net psexec

No comments:

Post a Comment