The fact that someone started a thread to ask which is better, if/else or case switch bothers me a little. The fact that no one had the right answer makes me leary of asking this question here, but I have few other sources:

I am kluging the hell out of this code to get it to ftp to the mainframe. I have hunted and hunted and ftping seems to be something VB can handle in only the most superficial of manners.

My way around this is to get VB to launch the batch to spawn the ftp session. When I do this I grab the PID of the cmd that the batch runs in. What I want to do now is wait for that process to exit. I have developed another kluge for this, but I am starting to run out of duct tape, and neither of these methods are stable or robust enough to recover from an error.

My question is; what is the most robust way of waiting for the process to exit when you have not a handle, but a PID?

-Travis