[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Threads with Sockets

Posted on 1998-08-07
1
Medium Priority
?
143 Views
Last Modified: 2010-04-04
I'm trying to create a thread object that contains a TClientSocket component.  I need this so I can create new threads to send messages to my server and then end when they have sent the message (or timed out).  I've done most of it, but the TClientSocket is not receiving any messages to say it's connected or timed out.  I get the connecting message but stepping through the code for the component shows that that event is fired before the socket is attempted to connect anyway.  Does the component use Windows messages to work ?  I tried to call the create for the ClientSocket with my TForm1 as the owner and it still didn't work.  Any help appreciated.

Daz
0
Comment
Question by:Dazza051197
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 8

Accepted Solution

by:
ZifNab earned 200 total points
ID: 1361724
Dazza,

 Did you know about the freeware components of F.Piette?
 No, well you should! They are far more better than the Delphi ones (at least these of D3). You get free help! Anytime! And most of all (for your purpose), you can use these components on two ways :

 1. Synchronious, program waits until command terminated
 2. Asynchronious, program doesn't wait = far better then threads (François has shown a demo about these two)

On his site, lot's of demo's too. I hope I've convinced you to use F.Piette's components.

PS. They keep the same also, we can't say this about Inprises components! D3 <> D4 <> ...?


here is the url. : http://www.rtfm.be/fpiette/indexuk.htm

Please, look at it!!! I assure you it's better than in your dreams!

Problems? Just ask or ask it at their free mailing list.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
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…
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Suggested Courses

650 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