I created a yahoo messenger and i'm able to receive the packets and decrypt them with this function that i got off of PlanetSourceCode.com

Code:
Function StripKey(Expression$, tString$) As String
Dim Keys() As String
StripKey = Expression
For tLoop = 0 To Len(tString) + 5000
StripKey = Replace(StripKey, Mid$(tString$, tLoop + 1, 1), Empty)
Next
End Function
I can get the raw date send it to the function and it comes out with a number and a string. The number, just say is the number 1 then it would mean i'm successfully connected and the number 2 means i'm disconnected. What my question is, when i view the raw data it only consists of the this string "YCHT". How is it possible to pull a number and a 500 CHR string out of that? Also if someone could explain to me how the code above works. Thank you.