SerialPort.ReadBufferSize Property
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets or sets the size of the SerialPort input buffer.
public:
property int ReadBufferSize { int get(); void set(int value); };
public int ReadBufferSize { get; set; }
[System.ComponentModel.Browsable(true)]
public int ReadBufferSize { get; set; }
member this.ReadBufferSize : int with get, set
[<System.ComponentModel.Browsable(true)>]
member this.ReadBufferSize : int with get, set
Public Property ReadBufferSize As Integer
The buffer size, in bytes. The default value is 4096; the maximum value is that of a positive int, or 2147483647.
- Attributes
The ReadBufferSize value set is less than or equal to zero.
The ReadBufferSize property was set while the stream was open.
The ReadBufferSize property was set to an odd integer value.
The ReadBufferSize property ignores any value smaller than 4096.
Because the ReadBufferSize property represents only the Windows-created buffer, it can return a smaller value than the BytesToRead property, which represents both the SerialPort buffer and the Windows-created buffer.
Produit | Versions |
---|---|
.NET | 8 (package-provided), 9 (package-provided) |
.NET Framework | 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7 (package-provided), 4.7, 4.7.1 (package-provided), 4.7.1, 4.7.2 (package-provided), 4.7.2, 4.8 (package-provided), 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided) |
Commentaires sur .NET
.NET est un projet open source. Sélectionnez un lien pour fournir des commentaires :