ThbTapiCall.GatherDigits
Unit: hbTapi

This property defines and initiates the buffered gathering of digits on the call. The GatherDigits property of ThbTapiLine is used as a default for this property.

This property has the following sub-property:

Active
DigitModes

FirstDigitTimeout

InterDigitTimeout

NumDigits

TerminationDigits

Availability

Design-Time: None / Run-Time: Read, Write

Declaration

property GatherDigits : ThbTapiCallGatherDigits;

See Also

ThbTapiLine.OnDigits, ThbTapiLine.CallOptions.GatherDigits


Active (Boolean)

This property initiates the gathering of digits. Although this function can be invoked in any call state, digits can typically only be gathered while the call is in the connected state. When the gathering is complete the ThbTapiLine.OnDigits event fires with a Termination parameter with a value of LINEGATHERTERM_BUFFERFULL and this property is set to False.

Set this property to False to cancel an active gathering of digts. The ThbTapiLine.OnDigits will fire with a Termination parameter with a value of LINEGATHERTERM_CANCEL.

Errors

Using this function may cause an EhbTapiError exception . Possible errors are:

LINEERR_INVALCALLHANDLE, LINEERR_NOMEM, LINEERR_INVALCALLSTATE, LINEERR_NOTOWNER, LINEERR_INVALDIGITMODE, LINEERR_OPERATIONUNAVAIL, LINEERR_INVALDIGITS, LINEERR_OPERATIONFAILED, LINEERR_INVALPARAM, LINEERR_RESOURCEUNAVAIL, LINEERR_INVALPOINTER, LINEERR_UNINITIALIZED.

DigitModes (DWord)

The digit mode(s) to be monitored. This parameter uses one or more of the LINEDIGITMODE_ Constants:

Constant

Meaning

LINEDIGITMODE_PULSE

Use this mode to detect rotary pulse sequences to signal digits. Valid digits are 0 through 9.

LINEDIGITMODE_DTMF

Use this mode to detect DTMF tones. Valid digits are 0 through 9, '*', '#', 'A', 'B', 'C', and 'D'.

LINEDIGITMODE_DTMFEND

Use this mode to detect DTMF tones and detect the down edges. Valid digits are 0 through 9, '*', '#', 'A', 'B', 'C', and 'D'.

FirstDigitTimeout (DWord)

This member defines the time duration in milliseconds in which the first digit is expected. If the first digit is not received in this timeframe, the digit collection is aborted and the OnDigits event is triggered with a Termination parameter of the value LINEGATHERTERM_FIRSTTIMEOUT.

InterDigitTimeout (DWord)

This member defines the maximum time duration in milliseconds between consecutive digits. If no digits is received in this timeframe, the digit collection is aborted and the OnDigits event is triggered with a Termination parameter of the value LINEGATHERTERM_INTERTIMEOUT.

TNumDigits (DWord)

The number of digits to be collected before a OnDigits event is triggered (in TAPI terms a LINE_GATHERDIGITS message is sent).

TerminationDigits (String)

Specifies a string of termination digits as text characters. If one of the digits in the string is detected, that termination digit is appended to the buffer, digit collection is terminated, and the OnDigits event is called.