Subscribe to the given channel, with an optional callback and token object.
The specified callback will be called to deliver messages sent with the
specified channel number. If null is specified for the callback, messages
sent with the specified channel number will be delivered to the receiver's
normal callback.
Only one callback may be registered for a given channel. If this method is called
twice with the same channel number, an error will result.
![](../icons/collapse_all.gif)
Declaration Syntax
![](../icons/collapse_all.gif)
Parameters
- channelNumber (Int64)
- A positive integer indicating the channel to subscribe to
- cb (LBMReceiverCallback)
- An option callback to be called for messages on the specified channel
- cbArg (Object)
- A token to be passed to the specified callback. If null is specified for the cb argument, this argument will be ignored.
![](../icons/collapse_all.gif)
Exceptions
Exception | Condition |
---|
| Invalid argument or unexpected operational behavior has been encountered by unmanaged LBM C layer function. Most likely due to attempting to subscribe to a channel for which a subscription already exists.
|
Assembly:
lbmcs (Module: lbmcs) Version: 5.3.6.0