|
PortController.NET
Break Property
Sets and returns the state of the break signal.
Syntax
[Visual Basic]
object.Break [ = value ]
[C#]
object.Break [ = value ]
[C++]
object->Break [ = value ]
Parameters
object
An object expression that evaluates to a PortController object.
value
A boolean value representing the state of the break signal.
Return Value
All data in the transmit queue is cleared when the Break property is
set to true.
Default
false
Errors
Setting this value while the port is closed causes PortController to throw
a "Port is closed" exception. You may read this value while the port is closed but the returned value
is meaningless as it does not represent the current or initial break state of the port.
Example
[Visual Basic]
'Set break
myPortController.Break = True
'Get break status
Dim breakStatus As Boolean
breakStatus = myPortController.Break
[C#]
// Set break
myPortController.Break = true;
// Get break status
Boolean breakStatus = myPortController.Break;
[C++]
// Set break
myPortController->Break = true;
// Get break status
Boolean breakStatus = myPortController->Break;
See Also
BreakSignal Event | Dsr property | Rts property | SendXon method | SendXoff method
|