_ERRORLINE - QB64 Wiki

_ERRORLINE

From QB64 Wiki

Jump to: navigation, search

The _ERRORLINE function returns the source code line number that caused the most recent runtime error.



Syntax:

e% = _ERRORLINE


Description:

  • Does not require that the program use line numbers as it counts the actual lines of code.
  • The code line can be found using the QB64 IDE or any other text editor such as Notepad.
  • Used in QB64 program error troubleshooting ONLY.


Example: Displaying the current program line using a simulated ERROR code.

ON ERROR GOTO DebugLine 'can't use GOSUB ERROR 250 'simulated error code END DebugLine: PRINT _ERRORLINE RESUME NEXT


See also:



Navigation:
Go to Keyword Reference - Alphabetical
Go to Keyword Reference - By usage
Go to Main WIKI Page
Views
  • Page
  • Discussion
  • View source
  • History
Personal tools
  • Log in
Toolbox
  • What links here
  • Related changes
  • Special pages
  • Printable version