I am trying to import data from excel to my journal, but if there is a conversion error, it just blocks my journal. I want to make try/catch exception, but it does not work.
My code looks like this:
try { [My insert code] } catch (Exception::Error) { throw error("error here"); }
Error looks like this:
Error executing code: Wrong type of argument for conversion function.
And first suggestion probably will be "Fix the conversion code", but it wouldnt resolve my problem... Does anyone know why my catch block does not see that error? I tried to find exception for conversion errors, but there is like 0 information about it on internet.
Try without this (Exception::Error) because it is probably that your code does not give an Error exception.
(Exception::Error)
try { [My insert code] } catch { throw error("error here"); }
1.4m articles
1.4m replys
5 comments
57.0k users