
Port
Sets the COM port number.
■ Syntax
[VB]
Public Property Port As Integer
[C#]
public int Port {get; set}
■ Property
COM port number
Parameter value(s)
: 1: Connector interface, 4: IrDA
Default value
: 4
■ Exceptions
Name of Exception Meaning
InvalidOperationException The COM port is already open.
■ Note
If the value of this property is changed while COM port is open, an exception will be
thrown.
The value specified for this property will be valid the next time a send or receive
operation is performed.
If an invalid value is specified for this property, no exceptions will be thrown
immediately; however, an exception will be thrown later when an attempt is made to
send or receive data.
[Ex.] Acquire selected port number
[VB] Dim Port As Integer = MyFileTransfer.Port
[C#] int Port = MyFileTransfer.Port;
365
Kommentare zu diesen Handbüchern