Two approaches:
First- refine your code, trap the errors .
Second - install an error handler, for errors you can't foresee.
I gave up on trying to locate a list of error constants; you could have gotten addtional help from me, IF YOU SUPPLIED DETAILs of what error 13 is.
Steve