G
Guest
Hello All
I have the following code below that starts an external process batch file.
I would like to have the application display a dialog box confirming that the
process has ended. When I run the code below, I get an exception error
An unhandled exception of type 'System.InvalidOperationException' occurred
in system.dll
Additional information: No process is associated with this object.
Here is the code
Public Sub UploadFile()
Dim p As New Process
p.Start("c:\ofac\ftpUpload.cmd")
Do While p.HasExited = False <-- Here is where the error occurs
Loop
If p.HasExited = True Then
MsgBox("File successfully uploaded", MsgBoxStyle.Information,
"OFAC File Generator")
End If
End Sub
I have the following code below that starts an external process batch file.
I would like to have the application display a dialog box confirming that the
process has ended. When I run the code below, I get an exception error
An unhandled exception of type 'System.InvalidOperationException' occurred
in system.dll
Additional information: No process is associated with this object.
Here is the code
Public Sub UploadFile()
Dim p As New Process
p.Start("c:\ofac\ftpUpload.cmd")
Do While p.HasExited = False <-- Here is where the error occurs
Loop
If p.HasExited = True Then
MsgBox("File successfully uploaded", MsgBoxStyle.Information,
"OFAC File Generator")
End If
End Sub