Small Visual Basic 3.1:
You can download the sVB installer from the VS marketplace.
Small Visual Basic is the visual version of Small Basic, and the small version of Visual Basic.
-
After installing Small Visual Basic, you can double-click the "sVB samples" icon on the desktop to open the sVB samples folder, which is installed on your documents folder with more than 90 samples, including the Ball, Cars, Tetris, Tom and Jerry games, and many other interesting samples.
-
You can also double-click the "sVB docs" icon on the desktop to open the sVB reference PDF book, which contains the full documentation of the sVB IDE, syntax, and library.
-
The reference book may not be the easiest way for kids and beginners to start learning sVB with, and this is why I am publishing the "Small Visual Basic Kid Programmer" book series on Amazon.
In 1 May, 1964, John G. Kemeny and Thomas E. Kurtz created BASIC, which became the easiest and most popular programming language ever, with more than 300 different dialects that emerged and vanished over time.
But the major breakthrough in history of BASIC happened 27 years later, when Bill Gates decided to add the Alan Cooper's visual designer to QBasic to create Visual Basic. Visual Basic was released in May 1991 to became the most popular rapid application programming language (RAD) in that decade, and used by millions of students and unprofessional programmers to solve daily problems, especially after Microsoft integrated Visual Basic for Applications (VBA) in its Office products like Access and Excel, to make creating database apps a piece of cake. In 2002, Visual Basic had evolved to become Visual Basic .NET, a fully objected oriented language with so many advanced features, that made it the most powerful BASIC dialect ever, but on the cost of being more and more harder over the successive releases in the next 2 decades. This is why Vijaye Raji created Small Basic in 2008, which has only 14 keywords with a simplified syntax to be an easy educational language for kids and beginners starting from age of 8 and above. Small Basic has only two windows: The TextWindow which allows kids to do basic input and output operations, and the GraphicsWindow which allows them to draw shapes and create games. Small Basic did a great job and used in many schools, but it was not updated after 2013, while Scratch and Python popularity among kids and beginners increased rapidly in the last decade. That is why in 2021, Mohammad Hamdy decided to take the same step Bill Gates and Alan Cooper took when they moved from QBasic to Visual Basic, so, he added a visual form designer to Small Basic to became Visual Small Basic, making the necessary improvement to the code editor, compiler and code library to make it easy to crate windows forms application, so finally Small Basic became actually a Small Visual Basic! Small Visual Basic continued to evolve over the past three years, until it reached version 3.0 which introduced a debugger to the language, with many other improvements.Let’s see in short points some of what sVB can do. For full details on what you can do with sVB and how you can do it, see the sVB full reference PDF:
- sVB can be used to introduce programming to 6 years old kids and above, in any easy and simple way. Using the form designer to graphically design windows, allows to create amazing applications with few lines of code. All you need is to prepare some attractive images, drag them on the form designer, and use the animation methods to write some short and funny applications that interests small kids (see the animation and Jerry projects in the samples folder).
- sVB can create applications that show one or more window, draw simple and advanced graphics and animate them, play sounds, open and save files, create games, and so many other interesting things. The sVB samples folder, which is installed with language, contains more than 90 different samples, including the Ball, Cars, Tetris, Tom and Jerry games, and many other interesting samples.
- You can use the sVB Evaluator to evaluate math expressions at run time, which allows you to create an application to draw any function. See the "Draw Functions" project in the sVB samples folder.
-
sVB can define test functions and you can use the UnitTest library to run them and show the test results.
-
The sVB Lib folder now includes the LitDev library, so you can use it directly in your code.
-
sVB can run a subroutine in a new thread by using it as a handler to the Thread.SubToRun event, which is not actually an event, but it will run the subroutine immediately in a new thread. So, you can set the handler of this event as many times as you need (but don't exceed 100 threads). Ex:
Thread.SubToRun = Task1
Thread.SubToRun = Task2
- Small Visual Basic is easier than Python for kids and young beginners!
- Python is a full stack language, while sVB is only for desktop apps and only for educational purposes, which make it more focused on its purpose. But this doesn't mean sVB has no future, or it is just a toy. It is actually the doorway to a popular and powerful development platform: the DotNET and VS .NET. It is easy to use your understanding of sVB syntax, library, form designer, and even the code editor experience to move to VB .NET (and later to C# if you want). But actually sVB has some advanced topics, like designing a multi-form application, using XAML styles, using multi-threading and creating code libraries. sVB also comes with the LitDev external library that contains a 3D engine and a Physics engine, which allows endless advanced possibilities.
- Both Python and sVB are dynamically typed languages, but sVB is easier in this aspect, because it doesn't require type conversions.
- Python is case-sensitive (and surprisingly, the True and False keywords starts with uppercase letters), while sVB is case-insensitive, and the code editor makes sure to fix words to their original casing. This makes it more easier to learn.
- Python lists have 0-based indexes, while sVB arrays by default have 1-based indexes, which is more natural and easier for kids to deal with, but nothing prevents them from using the 0 index or even negative indexes, because arrays in sVB are actually dictionaries, so indexes are actually keys!
- Trigonometry functions use radian angles in Python. This is the default case in sVB, but you can disable this behavior to use degrees by using: Math.UseRadianAngles = False
- Python for loops can be confusing because of the range exclusive end:
for i in range(5, 0, -1):
print(i)
while for loops are very simple in sVB:
For I = 5 To 1 Step -1
TW.WriteLine(I)
Next
- Python block indentation is confusing for kids, and make nested statement harder to understand and more error borne because of miscounted spaces, while sVB uses end blocks (like EndIf, EndSub, and Next) which makes the code readable and well constructed. The sVB editor automatically adds the end block token while the kid is typing. It also adjusts block indentation and pretty-lists spaces and identifier casing. It even enforces a variable casing rule: local vars and parameters start with a lowercase, while global vars, subroutines and functions start with uppercase. So, in sVB, kids focus only on the code logic, not formatting!
- The sVB IDE is easy and powerful to deal with forms and graphics.
- The sVB source code is fully written with VB .NET and published on GitHub. All sVB projects are WPF projects, that target the .NET framework 4.5. You can run the source code in VS.NET 2019 and later. But before running the code, please copy the "Lib" and "Toolbar" folders from the "SmallBasicIDE\SB.Lib" folder to both "SmallBasicIDE\bin\Debug" and "SmallBasicIDE\bin\Release" folders.