System to program a forward?

Hello to all,

I am trying to put a system in my asterisk (1.4) with wich I can program puntually a forward in my phones to a external line.

I have made the next modifications to my extensions plan and I can program the number to be forwarded if I call from a sip, but if the incoming call is from outside my office, the forward does not work. Any idea? What am I doing wrong?

[oficina] is my incoming internal context
[callfwd-add] is the context to store the forward number
[callfwd-add] is the context to delete the forward

exten => 20,1,Answer()
exten => 20,n,Set(NUM=${DB(${EXTEN}/FORW)})
exten => 20,n,GotoIf($["${NUM}" = “”]?normal:forw)
exten => 20,n(normal),Dial(SIP/juanma,30)
exten => 20,n,Hangup()
exten => 20,n(forw),DIAL(misdn/g:outgoing/${NUM},60)
exten => 20,n,Hangup() ; terminamos la llamada

exten => s,1,Answer()
exten => s,n,Set(NUM=${CALLERID(num)})
exten => s,n,Set(COUNT=1)
exten => s,n(inicio),Playback(please-enter-the&telephone-number&for&your&call-forwarding&astcc-followed-by-the-pound-key)
exten => s,n,Read(forw,15,2,10)
exten => s,n,Playback(call-forwarding)
exten => s,n,Playback(has-been-set-to)
exten => s,n,SayDigits(${forw})
exten => s,n,Playback(if-this-is-correct-press&digits/1&if-this-is-not-correct&digits/2)
exten => s,n,Read(sino,1,5)
exten => s,n,GotoIf($["${sino}" = “1”]?setf:conta)
exten => s,n(conta),Set(COUNT=$[${COUNT} + 1])
exten => s,n,Gotoif($["${COUNT}" < “4”]?inicio:bye)
exten => s,n(setf),Set(DB(${NUM}/FORW)=${forw})
exten => s,n,Wait(1)
exten => s,n(bye),Playback(goodbye)
exten => s,n,Hangup

exten => s,1,Answer
exten => s,n,Set(NUM=${CALLERID(num)})
exten => s,n,Wait(1)
exten => s,n,Set(forw=${DB_DELETE(${NUM}/FORW)})
exten => s,n,Playback(call-fwd-cancelled)
exten => s,n,Playback(goodbye)
exten => s,n,Hangup

I have this two lines to enter and remove the forward

exten => 71,1,Goto(callfwd-add,s,1)

exten => 72,1,Goto(callfwd-remove,s,1)

Thank you so much