BaudRate Property
Sets and returns the baud rate communications parameter.
Syntax
Visual Basic
object.BaudRate [ = value ]
Visual C++
object.GetBaudRate()
object.SetBaudRate(value)
| Part
| Description |
| object |
An object expression that evaluates to a GPS ToolKit object. |
| value |
An integer representing the baud rate of the communications port.
|
Example
Visual Basic
'Set baud rate
myGPSToolKit.BaudRate = 4800
'Get baud rate
Dim baudRate As Long
baudRate = myGPSToolKit.BaudRate
Visual C++
// Set baud rate
_variant_t vtBaudRate((long)4800);
m_myGPSToolKit.SetBaudRate(vtBaudRate);
// Get baud rate
vtBaudRate = m_myGPSToolKit.GetBaudRate();
long baudRate = (long)vtBaudRate;
Remarks
Valid baud rates are 4800 and 38400.
Default
4800
Returns
A VARIANT (type VT_I4/long) containing the baud rate of the port.
Errors
Attempting to set BaudRate to an invalid value
will cause GPS ToolKit to throw an "Invalid argument" exception.
See Also
Open(), Close()
|