Back to product page
- Introduction
- License agreement
- Classes
- Enumerations
- Exceptions
- WeOnlyDo.Server.WebServer
- WeOnlyDo.Server.WebHeader
- WeOnlyDo.Server.WebHeaders
- WeOnlyDo.Server.WebRequest
- WeOnlyDo.Server.WebResponse
- WeOnlyDo.Server.WebSessions
- WeOnlyDo.Server.WebSessionVar
- WeOnlyDo.Server.WebSessionVars
- WeOnlyDo.Server.WebUpload
- WeOnlyDo.Server.WebUploads
- WeOnlyDo.Server.WebUser
- WeOnlyDo.Server.WebUsers
- How to get support?
WebSocketReceiveText method
Receives text from WebSocket.
Type
StringSyntax
- C#
- VB.NET
String WebSocketReceiveText(long Count[=0]);
The WebSocketReceiveText(Count) syntax has these parts:
The WebSocketReceiveText(Count) syntax has these parts:
Count | Long value. Determines number of bytes to receive. You can use 0 for all available bytes (default value). |
Return value | Received data provided as String value. |
Sub WebSocketReceiveText(ByVal Count As Long) As String
The WebSocketReceiveText(Count) syntax has these parts:
The WebSocketReceiveText(Count) syntax has these parts:
Count | Long value. Determines number of bytes to receive. You can use 0 for all available bytes (default value). |
Return value | Received data provided as String value. |
Remarks
This method allows you to read data previously arrived through the websocket. While data was arriving, WebSocketDataEvent event fired (more than once, perhaps), and you can allow wodWebServer.NET to buffer the data as it comes. When you're ready to consume it, call this method.Best moment to use this method is when WebSocketDataEvent event has FrameSize argument set to frame size - at which point you know frame is complete and you should read it and process in some way.
To send data back to websocket, use WebSocketSendText method.