Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CC6 Script

Status
Not open for further replies.

seekoksin

Programmer
Joined
Dec 25, 2002
Messages
8
Location
SG
Hi,

Can anyone advise whether having a COLLECT within another COLLECT workable or not? Example below..

OPEN VOICE SESSION
PLAY PROMPT VOICE SEGMENT <voice_segment>
COLLECT 1 DIGITS INTO first_digit_cv INTER DIGIT TIMER 2
/* checks the first digit, and collect again another
* 4 digits
*/
IF(first_digit_cv = 8) THEN
COLLECT 4 DIGITS INTO menu_choice_cv INTER DIGIT TIMER 2
END IF
END VOICE SESSION


Thanks
 
In theory this should work: COLLECT statements are between an OPEN and an END VOICE SESSION. Since the maximum number of digits for first_digit_cv is 1 the first COLLECT will end after pressing a number. If an '8' was pressed the second COLLECT statment will start collecting in the menu_choice_cv variable.

But does the caller know more digits has to folow (after first_digit_cv = '8')? Since there is no voice segment telling this.




 
The requirement is for the initial "COLLECT" to allow caller to enter option "1", "2", "8<extension of 4 digits> (e.g. 81234)". Hence, do u think it will still work?

thks
 
Yes;
* After pressing option "1" your call flow will stop (hence, will continue processing statementents after END VOICE SESSION).
* After pressing option "8" the system will start collecting (max 4) new digits (into the variable 'menu_choice_cv'). When no digits are entered (before the 'inter digit timer' of 2 seconds expires) the system will continue processing statementents after END VOICE SESSION.

In theory this collection should work.
Only if a caller presses '81234' very quickly and the system is very busy (slow) it might happen the system does not recieve the second digit '1'. I do think that will not happen in practice.

I usually setup a (small) test with a Test_CDN to test new configurations;
IF first_digit_cv = 1 THEN route call My_Mobile END IF
IF first_digit_cv = 8 AND menu_choice_cv = 1234 THEN route call My_FixedNbr END IF

 
thks...Yes, I agreed with you is to have a test setup. Unfortunately, I do not have such an environment in my office. In addition, no access to customer site to test it out.
 
Just tested this setup: It worked fine.
So my theory was correct ;-)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top