I need help with a portion of my application. I'm trying to run psexec.exe from my vb.net application. Everything is working fine execpt when i run the command by clicking a button... The command Window will show executing the psexec command. However the application locks until the command is completed.
Anyone know how to run the psexec command without the entire application freezeing?
Dim p As New Process()
p.StartInfo.FileName = "C:\pstools\psexec.exe"
p.StartInfo.Arguments = "\\" & TextBox1a.Text & " -s cmd /c c:\userMigration\scanstate.exe c:\%user% /o /all /c /i:migapp.xml /i:miguser.xml /i:migsys.xml /nocompress /localonly"
Catch ex As Exception
MessageBox.Show("Could not compete action")
I think i answered my own question.. I just removed the "p.WaitForExit()". The command now runs without locking up... However do anyone know how to hide the command winodow while its running??