[Migrated content. Thread originally posted on 13 December 2006]
I need to know if there is a way to stop a CALL "C$SYSTEM" command from within cobol. I'm trying to create a communications server that will call batch scripts which in turn invoke a communications program. I need to be able to stop the communications program from with in the server application, so if a user starts a long communication process, they will be able to cancel / stop it from the screen application.The way I have the Server application set up is it has a thread that is monitoring a message que file for commands to process. When it receives a command to process from a User, it performs that process (batch file) invoking the communications process. When the comm process is complete, it then changes the status of the message record so that the user application knows that it was complete and they can continue processing. While the communications is taking place the User has a screen with a timer indicating how long it has been taking, plus a cancel button that would allow them to stop the communication process.
I haven't tried anything yet, but was thinking of using a thread to start the comm process, then I could cancel the thread, but I don't know if the "C$SYSTEM" call would work that way. BTW, this is on a Windows System.
Thanks,



