Displaying 1 result from an estimated 1 matches for "hold_loopcount".
2009 Mar 06
1
GoSub & Queue
...amp;from&${SCREEN_FILE}&screen-press-1-connect&screen-press-2-hold&screen-press-3-voicemail&/screen-press-4-hangup)
exten => s,4,WaitExten(20)
;; Connect the caller
exten => 1,1,Set(GOSUB_RESULT="")
exten => 1,2,Return
;; Put Caller on Hold
exten => 2,1,Set(HOLD_LOOPCOUNT=0)
exten => 2,2,read(HOLD_OPT,screen-on-hold,1,,1,5)
exten => 2,3,GotoIf($["${HOLD_OPT}" != "" ]?s,1)
exten => 2,4,GotoIf($[${HOLD_LOOPCOUNT} > 10]?h,1)
exten => 2,5,Set(HOLD_LOOPCOUNT=$[${HOLD_LOOPCOUNT}] + 1])
exten => 2,6,Goto(2,2)
;; Send the caller to voic...