Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 1 of 1 total
Thread Cleanest way to deal with server disconnection
Fri, Mar 11 2022 11:44 AMPermanent Link

Adam Brett

Orixa Systems

I have client-server Applications, built with Delphi, running on Windows.

An Instance of EDBSRVR.exe will be running somewhere, and the App accesses it over a LAN or WAN.

I am trying to figure out the best way to handle a situation where my App suddenly finds that the EDBSRVR has "gone".

My Apps are data-intensive, with a lot of data-entry. Once a connection is lost, I would like to just say to the user "Try to reconnect?" & if the reconnect fails, exit.

There are a number of ways to check for connection, and also events (for example Session.BeforeDisconnect or Session.AfterDisconnect) that I could use to trigger the code.

At present I don't do anything ... as EDBSRVR is really reliable so I haven't needed to!

But I really should, as there are occasions when data disconnects, and at present that ends up with a lots of unprofessional error messages showing in my App.

How do other coders do this?
Image