Private Sub Winsock1_DataArrival
(ByVal bytesTotal As Long
)
Dim str As String
Winsock1.GetData str, vbString, bytesTotal
Text1.Text = str & "bytes: " & bytesTotal
End Sub
Ugly and not very good code, but I'll change crap like str and Text1 as soon as it really works.
I was checkin' out the help file with it:
----
GetData
This method retrieves the current block of data from a Winsock control.
winsock.GetData data [,type],[maxLen]
Parameters
winsock
Reference to a Winsock control.
data
Variable where retrieved data is stored.
type
Optional parameter indicating the format of the returned data. Must be either vbString or
(vbByte + vbArray
). If not specified, defaults to vbString.
maxLen
Optional parameter included for compatibility with the Visual Basic 6 WinSock control. Currently not implemented; if a value is specified, it is ignored.
----
And then I noticed this which might be my problem:
If you receive data as a string, the bytes are converted from ASCII characters to Unicode characters. The conversion will stop if the data contains a NULL byte
(ASCII code 0
); data may be lost as a result. If you need to receive data that contains NULL bytes, you must use
(vbByte + vbArray
).
I'm just getting basic text
(song titles
). If I can get song titles going I can add in artist and album, but for now I need to get the damn thing workin'!
I know the server works because the only time it displays the song is if it sent the data okay, and it displays it fine. So I know the problem is on the PDA end.
I'm pretty furstrated as hell and I'd post up the whole code, but right now it's in such a disarray and not ready for the public
(I need to make it pretty!
). No less if I can get it to display songs and what not all right then I'll put something up and then get workin' on adding library support.
I'm getting sleepy *grumbles off to the fridge*