Results 1 to 6 of 6

Thread: TCP / IP and Arrays?

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Mar 2000
    Location
    Omaha, NE, USA
    Posts
    28
    The client to server winsock program I am working is constantly sending a waleth of data back and forth. However, I just became aware I can not .senddata with arrays. What would you suggest for send several bits of information at once?
    - Ovid -

  2. #2
    Hyperactive Member
    Join Date
    Mar 2000
    Location
    Boulder, Colorado, USA
    Posts
    325
    what is in your arrays?
    -Shickadance

  3. #3

    Thread Starter
    Junior Member
    Join Date
    Mar 2000
    Location
    Omaha, NE, USA
    Posts
    28

    What is in your arrays?

    Just strings.
    Example:
    Public Outgoing(1 to 20) as String
    Outgoing(1) = Action
    Outgoing(2) = UserID
    etc...
    Client.Senddata
    - Ovid -

  4. #4
    Hyperactive Member
    Join Date
    Mar 2000
    Location
    Boulder, Colorado, USA
    Posts
    325
    yeah you are going to have to send each individually unless you can just concat all the strings and send out one big chunk.
    -Shickadance

  5. #5
    Lively Member
    Join Date
    May 1999
    Location
    Singapore
    Posts
    116
    you can combine the strings with something that is unique for the strings

    for ex.
    Outgoing(1)="Hi"
    Outgoing(2)="I"
    Outgoing(3)="am"
    Outgoing(4)="John"
    Outgoing(5)="!!!"

    for i=1 to Ubound(Outgoing) Step 1
    strOut=strOut+Outgoing(i)
    next i

    you can combine the elements with a "|" sign(Chr(127))

    than you can separated them with | as the delimiter
    YC Sim
    Teenage Programmer
    UIN 37903254



  6. #6

    Thread Starter
    Junior Member
    Join Date
    Mar 2000
    Location
    Omaha, NE, USA
    Posts
    28

    Originally...

    Yeah. Originally I was using the | as a seperator by which to take apart the information, but I am afraid that may end up causing to much thinking with the amount of data that will be sent back and forth from the amount of users at one time.
    - Ovid -

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width