Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Gets a value that indicates whether data is available on the NetworkStream to be read.
Namespace: System.Net.Sockets
Assembly: System (in System.dll)
Syntax
'Declaration
Public Overridable ReadOnly Property DataAvailable As Boolean
public virtual bool DataAvailable { get; }
public:
virtual property bool DataAvailable {
bool get ();
}
abstract DataAvailable : bool with get
override DataAvailable : bool with get
function get DataAvailable () : boolean
Property Value
Type: System. . :: . .Boolean
true if data is available on the stream to be read; otherwise, false.
Remarks
Use the DataAvailable property to determine if data is ready to be read. If DataAvailable is true, a call to Read returns immediately. If the remote host shuts down or closes the connection, DataAvailable may throw a SocketException.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see dd66cd4c-b087-415f-9c3e-94e3a1835f74.