Small Basic - Errors
I started to write a TechNet Wiki article about errors in Small Basic. At this point, I wrote about syntax errors and run time errors. But there might be more errors such like at Publish or Import. If you know other errors in Small Basic, please let me know or edit the TechNet Wiki article.
When you push [Run] button, there happens two phases. The first phase is compiling. The Small Basic Environment (SB.exe) calls compiler (SmallBasicCompiler.exe) to compile Small Basic source code to binary for .NET Framework. Then the second phase is running. The Small Basic Environment calls the generated binary.
At compiling time, the compiler checks the syntax of the source code. If there are any errors in it, the Small Basic Environment shows syntax errors. Following message is a sample of a syntax error. "1, 1:" means the number of line (row) and column of the error in the source code.
Sorry, we found some errors…
1,1: Subroutine 'Foo' is not defined.
These kind of syntax errors are listed on bottom in the active editor. If you click a line of error messages, the cursor will be moved to the line of the source code.
Run Time Errors
At running time, if there happens a trouble in Small Basic library, .NET Framework or Windows system, error popup will be displayed like below. In the text box, there is a stack trace. This includes names of subroutines which are called.