Skip to main content
Participant
June 26, 2017
Question

How to catch exception

  • June 26, 2017
  • 1 reply
  • 189 views

In asc code i have line:

if (new File(WRONG_PATH).open("utf8", "write")) {}

how to catch error because try/catch does not work.

Thank you in advance

    This topic is closed to new replies. Start a new post to keep the conversation going.

    1 reply

    Graeme Bull
    Community Expert
    Community Expert
    July 31, 2017

    It should return true or false, if false then "error" if not, then it succeeded.