By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,890 Members | 1,101 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,890 IT Pros & Developers. It's quick & easy.

Signal thread to abort

P: n/a
I have a thread which uses TcpListener to accept new nonnections.
I do this in Do/Loop statment
The "Do" statment is blocked when the TcpListener waits for new
connection.

I need a way to signal the thread to aborts itself.

If a make the "Do" statement to check with "Do While" or "Do Until",
but it is only checked each loop, which happens only when a connection
to the TCPListener is made.

Any ideas?

thanks

Nov 21 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
set the thread's IsBackground property to true, and the thread will quit when
the main thread quits.

"Nikolay Petrov" wrote:
I have a thread which uses TcpListener to accept new nonnections.
I do this in Do/Loop statment
The "Do" statment is blocked when the TcpListener waits for new
connection.

I need a way to signal the thread to aborts itself.

If a make the "Do" statement to check with "Do While" or "Do Until",
but it is only checked each loop, which happens only when a connection
to the TCPListener is made.

Any ideas?

thanks

Nov 21 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.