SerialConnection.Connect

From Xojo Documentation

Method

SerialConnection.Connect()

New in 2019r2

Supported for all project types and targets.

Attempts to open a connection to the serial device. If the connection could not be made, an IOException is raised.

Sample Code

Try
SerialConnection1.Connect
MessageBox("The serial connection is open.")
Catch error As IOException
MessageBox("The serial connection could not be opened.")
End Catch