You should use a network monitor (packet sniffer) to see if your message is sent or not accross the network. You'll then be able to understand if the problem is the sending side or the receiving side.

Most of the time, transmission doesn't work when the message pump is no more called or for some reason doesn't dispatch the messages properly.

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be

----- Original Message ----- From: "Markus Humm" <markus.h...@freenet.de>
To: "ICS support mailing" <twsocket@elists.org>
Sent: Monday, May 25, 2009 8:33 PM
Subject: Re: [twsocket] TWSocket doesn't always send my data?


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

--
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