J
JohnP
I am trying to execute a .bat file with the following code:
Dim objProcess As Diagnostics.Process
Dim objProcessInfo As Diagnostics.ProcessStartInfo
objProcess = New Diagnostics.Process()
objProcessInfo = New Diagnostics.ProcessStartInfo(Server.MapPath("COFile.bat"))
objProcess.StartInfo = objProcessInfo
objProcess.EnableRaisingEvents = True
objProcess.Start()
objProcess.WaitForExit()
It doesn't seem to be doing anything. Am I doing something wrong with the code?
Thanks.
John
Dim objProcess As Diagnostics.Process
Dim objProcessInfo As Diagnostics.ProcessStartInfo
objProcess = New Diagnostics.Process()
objProcessInfo = New Diagnostics.ProcessStartInfo(Server.MapPath("COFile.bat"))
objProcess.StartInfo = objProcessInfo
objProcess.EnableRaisingEvents = True
objProcess.Start()
objProcess.WaitForExit()
It doesn't seem to be doing anything. Am I doing something wrong with the code?
Thanks.
John