No previous pattern in the first entry of context match 'same' at extensions.conf!

Hello. I am going to develop a new IVR for my project. But following Issues was occurred.

[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'welcomeloop' to match 'same' at line 366 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'welcomeloop' to match 'same' at line 367 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'welcomeloop' to match 'same' at line 370 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'welcomeloop' to match 'same' at line 371 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'welcomeloop' to match 'same' at line 372 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'welcomeloop' to match 'same' at line 373 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'welcomeloop' to match 'same' at line 374 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'welcomeloop' to match 'same' at line 377 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'welcomeloop' to match 'same' at line 380 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'English_lang' to match 'same' at line 384 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'English_lang' to match 'same' at line 385 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'Sinhala_lang' to match 'same' at line 389 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'Sinhala_lang' to match 'same' at line 390 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'Tamil_lang' to match 'same' at line 394 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'Tamil_lang' to match 'same' at line 395 of extensions.conf!
[Jan 31 05:25:45] ERROR[8902]: pbx_config.c:1757 pbx_load_config: No previous pattern in the first entry of context 'Hangup' to match 'same' at line 399 of extensions.conf!


my code is bellow.

; DMSE IVR
[dmse_IVR]
exten => 0114732155,1,Answer()
   same => n,Set(tries=0)
   same => n,Goto(welcomeloop)

[welcomeloop]
; play welcome dms message for Language Selection
same => n,Playback(welcomedmse) ; line number 366
same => n,Read(user_inputs,,1,,3)

   ; User Inputs
   same => n,GotoIf($["${user_inputs}" = "1"]?English_lang)
   same => n,GotoIf($["${user_inputs}" = "2"]?Sinhala_lang)
   same => n,GotoIf($["${user_inputs}" = "3"]?Tamil_lang)
   same => n,Playback(WrongInput)
   same => n,Set(tries=$[${tries} +1])

   ; Check user input 3 wrong inputs
   same => n,GotoIf($[${tries}>=3]?Hangup)

   ; If user enters wrong input, Play welcomedmse voice again
   same => n,Goto(welcomeloop)

         [English_lang]
            ; If user presses 1, go to English Language
            same => n,Playback(welcome)
            same => n,Hangup()

         [Sinhala_lang]
            ; If user presses 2, go to Sinhala Language
            same => n,Playback(welcome2)
            same => n,Hangup()

         [Tamil_lang]
            ; If user presses 3, go to Tamil Language
            same => n,Playback(welcome)
            same => n,Hangup()

         [Hangup]
            ; Hangup after 3 wrong inputs
            same => n,Hangup()

How fix this issue?

You are going in another context, you have to give extension and priority from the new context

; DMSE IVR
[dmse_IVR]
exten => 0114732155,1,Answer()
   same => n,Set(tries=0)
   same => n,Goto(welcomeloop,s,1)

[welcomeloop]
; play welcome dms message for Language Selection
exten = s,1,NoOp(First priority in extension s)
  same => n,Playback(welcomedmse) ; line number 366
  same => n,Read(user_inputs,,1,,3)
...

Thank you !!!. That is solution

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.