Hello,

today I rewrote that part of the application but without success.
It now works like this: the GUI finds that the user wants to quit.
OnCloseQuery is called. Here a custom message (wm_user+100) is sentm, a
flag is set and can close is set to false. In ApplicationMessages the
GUI calls a com server routine which sends the connected other
application a command to quit. Line mode is used and the problem arises
when this command isn't received on the other side. Reason for this is
unknown. I will create a OnDataSend handler tomorrow to check if it has
been delivered to winsock at least. And a timeouttimer is started
(currently 10 sec.)

The other application will shutown and send back a message "shutdown
done". The com server will "translate" this into a com event and the GUI
will then stop the timeout timer and send another custom message
(wm_user+99). In ApplicationMessages a routine in the com server will be
called which will do a shutdown and close on the TWSocket. And the
application close is initiated now.

I had hoped that my message processing now works as it should normally,
but the other application sometimes (between 1-3 times out of 10 tried)
doesn't receive this message and I don't know why.

What else can cause this? Is my way of doing things now the proper one
(considering the com useage)?

Greetings

Markus
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to