|
IVR Software Library
ivr_prompt
Database Systems Corp. (DSC) provides an API subroutine library of IVR Software routines that perform phone functions The following is a description of one of the functions within this library that controls the IVR operation - ivr_prompt.
The routine is from our C programming library, although this same routine has an equivalent for Visual Basic, .NET, C++ and Active-X. DSC provides a separate user guide for each of these languages.
Contact DSC to obtain the most current IVR manuals in your required programming language.
ivr_prompt()
int
ivr_prompt(int call, char *wavefile, int allow_interrupt, int max_digits, int
timeout, char termchar, int clear, IVRDIGITS
*ivrd)
The
ivr_prompt function plays a message and retrieves the digits from the
specified call.
Parameters
int
|
call
|
Specifies
which call to retrieve digits from. It can be one of the following values.
CALL_PRIMARY: Collect Digits from the Primary Call
CALL_SECONDARY: Collect Digits from the Secondary Call
|
char *
|
wavefile
|
Null terminated string containing the pathname of the
message to play.
|
int
|
allow_interrupt
|
Specifies
if a digit can interrupt the prompts. It can be one of the following values.
NO_INTERRUPT: Prompts CANNOT be interrupted by a digit
INTERRUPT: Allow prompts to be interrupted by a digit
|
int
|
max_digits
|
The maximum number of digits to return. This must be less
than 32.
|
int
|
timeout
|
The maximum amount of time in seconds to wait for the
digits to be entered.
|
char
|
termchar
|
A specific character to terminate digit collection.
|
int
|
clear
|
Clear
the buffer before digit collection. It can be one of the following values.
NO_CLEAR: Do NOT clear the buffer before digit collection
CLEAR: Clear the buffer before digit collection
|
IVRDIGITS *
|
ivrd
|
Structure of type IVRDIGITS
in which the digits will be returned.
|
Return Value
Returns
IVR_SUCCESS on a successful function call. On error the function returns one of
the IVR Error Codes.
Example
IVRDIGITS ivrd;
if(ivr_prompt(CALL_PRIMARY,"D:\\ivrdemo\\prompt1.wav", INTERRUPT,1,15,'*',NO_CLEAR,&ivrd) != IVR_SUCCESS){ ...handle error; }
|
|