realbasic-nug
[Top] [All Lists]

RE: Socket Taking Over. Need a Thread?

To: "'REALbasic NUG'" <realbasic-nug at lists dot realsoftware dot com>
Subject: RE: Socket Taking Over. Need a Thread?
From: "RBNUBE" <rbnube at mabenterprises dot com>
Date: Sat, 29 Dec 2007 23:26:44 -0500
Delivered-to: listarchive at realsoftware dot com
Delivered-to: realbasic-nug at lists dot realsoftware dot com
Importance: Normal
Keywords: RB-NUG
Organization: N/A
Thread-index: AchKljLslVddG1htQ1CCSVBOc1obQgAApBWwAADRNoA=
BTW, if you already know how to do all of this, you might need to be more
specific about what it is that you're not sure about.
___________________________________________________________________

> Yeah - I'm just not sure how to handle that...

I've never done exactly what you're doing, so I'm not sure that I do either.
See my assumptions below...


> I have in the DataAvailable event code that reads what's in the socket 
> buffer and adding it to an string that is acting as a buffer.

I would assume that you would simply move your code to the thread Run event
and then call MyThread.Run from inside the DataAvailable event.

If you don't know how to use a thread, it's very simple.  Just drag a thread
into the window from the Control List.  Once you've done that, you can
access its Run event by double-clicking it.  You might have to adjust the
thread Priority to suit your needs.  I usually set the Priority to 1.  I
haven't noticed any ill effects from doing this.

HTH

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives:
<http://support.realsoftware.com/listarchives/lists.html>


<Prev in Thread] Current Thread [Next in Thread>