0
votes

I was recently given the task to write an application in Delphi XE6 that communicates with our legacy system (Delphi 2007). The old system uses TWSocket to drive the communication using its OnDataAvailable event on a socket level. TClientSocket and TServerSocket are also used and since those have been deprecated i would prefer to use modern components to replace them on my end. Is it possible to use the components supplied in Delphi XE6 (i.e. TIdTCPClient, TIdTCPServer)? Could you point to an example where this is done?

1

1 Answers

0
votes

Indy surely can be used as a replacement for these old / deprecated socket libraries.

OnDataAvailable is an asynchronous, non-blocking event handler, which requires a different programming style than Indy, which uses blocking TCP communication.

And depending on your specific code, the Indy components should be used in a separate thread to run independent of the application main thread.