|
-
Mar 15th, 2003, 08:56 AM
#1
Thread Starter
Addicted Member
Winsock Array
I have a winsock array, one winsock is created for each new user. WnskMain with an Index of 0 listens on a port, and then hands off the connection the new winscock control.
Under DataArrival(), i call a sub, which in turn will send data back to the user. But I don't know how to tell which winsock(port) the user is connected on. I have been told that it is included in the data being sent. Can anyone help me out?
-
Mar 15th, 2003, 12:41 PM
#2
Lively Member
if the Winsock object is an array of Winsock's, then each event will come with a new paramater called Index.. that Index is the index of the corressponding user.. when u call the sub, pass the Index with it, and within the sub, say somethin' like
VB Code:
Winsock1(Index).SendData "blah"
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|