Stop gently the process
true, if everything went OK and Invoke() finished during the call to this method, ie. m_invoked became 0. false if m_invoked was 1 the whole time, in this case call this method again and again until it succeeds, show an error messsage or thing about speeding up procedures called with doInvoke().
Calls the given stop procedure only, if no invokes are active. The given stop procedure usually contains calls to Thread.Join(), which, if called simultaneously with Invoke(), would cause hangs of the program. Therefore the procedure waits, calling Application.doEvents() maximally MAX_STOP_TRIES, until the flag m_invoked becomes false.
FormWithInvoke Class | serial Namespace