Solved

Delphi 7 & TidCmdTCPServer - Hangs on simultaneous calls to OnCommand.

Posted on 2007-04-10
3
447 Views
Last Modified: 2008-03-18
Hi All,

I am using Delphi 7 with Indy components, TidCmdTCPServer.
My application runs on a LAN and need to communicate with each other in this manner using Indy's TidCmdTCPServer component.
I have created several commands in the mentioned component.

But when I have 2 application sending the same command to my server application simultaneously all application (clients & server) hangs.

Does the OnCommand events of the TidCmdTCPServer automatically handles simultaneous calls to the same event?

Can some please assit me?

Thanks!
0
Comment
Question by:Marius0188
3 Comments
 
LVL 17

Accepted Solution

by:
TheRealLoki earned 500 total points
ID: 18914885
your code is likely not threadsafe. This is related to your other question.
I have an example of how to PostMessagess from within an indy thread (I prefer this to the IdSync method due to its' portability and compatiibility to Indy 9 and Indy 10)
http://sourceforge.net/projects/internetdemos
0
 
LVL 1

Expert Comment

by:Computer101
ID: 21156546
Forced accept.

Computer101
EE Admin
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now