.NET Framework 4.6 and 4.5
Gets the length in bytes of the stream.
Public Overrides ReadOnly Property Length As Long
Type: System.Int64A long value representing the length of the stream in bytes.
The following example uses the Length and Position properties to check for an end-of-file condition.
If s.Length = s.Position Then
Console.WriteLine("End of file has been reached.")
Supported in: 4.6, 4.5, 4, 3.5, 3.0, 2.0, 1.1
.NET Framework Client Profile
Supported in: 4, 3.5 SP1
Supported in: 3.0, 2.0, 1.0
.NET for Windows Phone apps
Supported in: Windows Phone 8.1, Windows Phone Silverlight 8.1, Windows Phone Silverlight 8