QB64.org Forum
Active Forums => QB64 Discussion => Topic started by: GTC on January 16, 2021, 02:23:44 am
-
If there's a wish list for future releases of QB64 then I can't find it here.
Apart from the implementation of ON COM (mentioned elsewhere), I would love to see the equivalent of VB's Err.Description:
The Err.Description provides details of the error that occurs. This is the text you normally see when an error occurs e.g. “Type Mismatch” The Err. Number is the ID number of the error e.g. the error number for “Type Mismatch” is 13.
Maybe _ERRORTEXT (ErrorNumber)
-
It's funny you mention this, I asked on discord last night if such a thing exists.
Should be easy enough to add; in the meantime here's the list if you'd like to copy it into your program: https://github.com/flukiluke/65/blob/master/src/errors.bm
-
Thanks for that!
It's more extensive than the Wiki list: https://www.qb64.org/wiki/ERROR_Codes
-
Yes, I copied it directly from the runtime function that generates the pop-up.
Perhaps one of the wiki people would like to update the wiki page.
Hang on, I'm one of the wiki people...
-
Notice that some of those errors are considered critical and won't even trigger the error handler - they'll fail and quit. Nevermind. You got the critical ones out.
-
We now (when the CI finishes building) have a _ERRORMESSAGE$ function.
It defaults to returning the message of the current error (i.e. in an ON ERROR handler), but will accept an argument for an explicit error number too.
-
🤩