On Mon, 21 Jan 2008, Doug Lytle wrote:
> Tzafrir Cohen wrote:
>>
>> exten => s,1,Set(COUNT=$[${COUNT} + 1])
>> exten => s,n,NoOP(${COUNT})
>> exten => s,n,GotoIf($[ ${COUNT} > 3 ]?endloop)
>> exten => s,n,Goto(1)
>> exten => s,n(endloop),NoOp(Loop ended)
>
> You forgot to initialize your variable.
>
> Set(COUNT=0)
Or...
Define MAX-COUNT in the global context (more obvious and maintainable),
assign it to COUNT at the top of your loop, decrement and compare to 0
(something about being an old PDP-11 assembly language programmer...)
Thanks in advance,
------------------------------------------------------------------------
Steve Edwards [EMAIL PROTECTED] Voice: +1-760-468-3867 PST
Newline Fax: +1-760-731-3000
_______________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-users