Invalid entry

Hi,

Here is part of my extension.conf

[general]
static=yes
writeprotect=no
clearglobalvars=no

[globals]

[cbmin]
include => vm
include => record
include => cbmlocal
include => conference

exten => 5555555555,1,Answer()
same => n,Read(digito,/abc,1,10)
same => n,NoOp(${digito})
same => n,GoToIf($["${digito}" = “1”]?sales)
same => n,GoToIf($["${digito}" = “2”]?custser)
same => n,GoToIf($["${digito}" = “3”]?techsup)
same => n,GoToIf($["${digito}" = “4”]?dir)
same => n,GoToIf($["${digito}" = “5”]?bob)
same => n,GoToIf($["${digito}" = “8”]?conf)
same => n,NoOp(Call Status ${DIALSTATUS})
same => n,GoToIf($["${DIALSTATUS}"=“NOANSWER”]?sales)
same => n(sales),Dial(SIP/6801,10,t,r)
same => n(custser),Dial(SIP/6802,10,t,r)
same => n(techsup),Dial(SIP/6803&SIP/6808,10,t,r)
same => n(dir),directory(default,cbmin,f)
same => n(bob),Dial(SIP/6808,10,t,r)
same => n(conf),Goto(conference,s,1)
same => n,Voicemail(6801,u)
same => n,hangup()

exten => i,1,Playback(sorry)
same => n,Goto(cbmin,start,1)

exten => t,1,Playback(goodbuy)
same => n,hangup()

when I call and enter an invalid number like 9 it does not play the message

here is the output from cli

*CLI> == Using SIP RTP CoS mark 5
– Executing [5555555555@cbmin:1] Answer(“SIP/xxxxx_in-0000000c”, “”) in new stack
– Executing [5555555555@cbmin:2] Read(“SIP/xxxxx_in-0000000c”, “digito,/abc,1,10”) in new stack
– Accepting a maximum of 1 digits.
– <SIP/xxxxx_in-0000000c> Playing ‘/abc.slin’ (language ‘en’)
– User entered ‘9’
– Executing [5555555555@cbmin:3] NoOp(“SIP/xxxxx_in-0000000c”, “9”) in new stack
– Executing [5555555555@cbmin:4] GotoIf(“SIP/xxxxx_in-0000000c”, “0?sales”) in new stack
– Executing [5555555555@cbmin:5] GotoIf(“SIP/xxxxx_in-0000000c”, “0?custser”) in new stack
– Executing [5555555555@cbmin:6] GotoIf(“SIP/xxxxx_in-0000000c”, “0?techsup”) in new stack
– Executing [5555555555@cbmin:7] GotoIf(“SIP/xxxxx_in-0000000c”, “0?dir”) in new stack
– Executing [5555555555@cbmin:8] GotoIf(“SIP/xxxxx_in-0000000c”, “0?bob”) in new stack
– Executing [5555555555@cbmin:9] GotoIf(“SIP/xxxxx_in-0000000c”, “0?conf”) in new stack
– Executing [5555555555@cbmin:10] NoOp(“SIP/xxxxx_in-0000000c”, "Call Status ") in new stack
– Executing [5555555555@cbmin:11] GotoIf(“SIP/xxxxx_in-0000000c”, “0?sales”) in new stack
– Executing [5555555555@cbmin:12] Dial(“SIP/xxxxx_in-0000000c”, “SIP/6801,10,t,r”) in new stack
== Using SIP RTP CoS mark 5
– Called SIP/6801
– SIP/6801-0000000d is ringing
== Spawn extension (cbmin, 5555555555, 12) exited non-zero on ‘SIP/xxxxx_in-0000000c’

DIALSTATUS is set by Dial. You haven’t yet called dial when you test for that value!

thanks David for the feed back and sorry for asking this question (new to asterisk but loving it though)

Could you let me know what I need to do so if a wrong number was dialed it routes correctly to invalid entry

tony

May I suggest to change your dialplan? Instead READ use BACKGROUND, instead all on same s extension create number extensions and use goto as command. Then your i and t extension can be used.