Hi Aratti, thanks for the answer.
Unfortunately the code still stands still at main function. I am attaching the main code here:

start:
GOSUB ONE
serout2 tx,baud,["AT+CMGD=1",13]
serin2 rx,baud,5000,start,[WAIT("OK")]
pause 1000
gosub one
serout2 tx,baud,["AT+CMGF=1",13]
Serin2 rx,baud,5000,start,[WAIT("OK")]
pause 1000
goto one
goto main


main:
gosub two
serout2 tx,baud,["AT^SMGR=1",13]
Serin2 rx,baud,5000,main,[WAIT("REC UNREAD")] ' Removed all STR statements to get it to work
goto start
one:
for c=1 to 10
portc=255
pause 20
portc=0
pause 20
next c
return
two:
for c=1 to 5
portc=255
pause 400
portc=0
pause 400
next c
return