Author Options:

Some questions about Microsoft Small Basic Answered

Hi there. I have been a user of the Microsoft Small basic programming language for a few weeks now, and i'm really bewildered by how amazingly easy and powerful it is. But I have a few questions about the more advanced features that the PDF tutorial didn't cover.

1) How do I use the File class? I know that it is used for saving progress and such, and would really like to add this to my programs, but the tutorial didn't say how to use it. (use example code, please).

2) What exactly is the Network class, and how do I use it? My best guess is that it creates some sort of telnet connection, (If so I can imagine a whole slew of Small Basic MUDs)

3) How do I use OnMouseClick events to make an image move to where the user clicks, Like in adventure games? This isn't probably something i'll be using for a while, but it's nice to know in case.

4) Are there any tutorials out there for the more advanced uses of Small Basic? The PDF Intro is very nice, but is pretty limited.

P.S: I'm thinking of doing an instructable on Small Basic, on learning the language and such. What do you think of this idea? And please don't flame me saying "Dud u Shud just lern C++" because I am not interested.

Thank you.


You may want to check out the different Small Basic Tutorials avaialble from http://www.computerscienceforkids.com. We produce several Small Basic tutorials including David Ahl's Small Basic Computer Adventures and the Beginning Small Basic Programming Tutorial which was recommended by Vijaye Raji (the creator of Small Basic). We will be releasing a more advanced "Programming Kid Games with Microsoft Small Basic Tutorial later this month. -Phil

Some of the advanced uses might be ridiculously complex in a small programming language. Perhaps you should install all the libraries and tutorials. Also, you could supplement the code with basic, which is the great-grandfather of Small Basic. Good choice for a starter language, through I would not recommend getting into Visual Basic, as it teaches bad habits and windows dependency.

It's been a few months since I posted this question, and I have accrued a couple answers to the questions since then.

1) I still don't know how to do this. Been messing around with it, to no avail. One of the advantages of using a BASIC dialect is it's not likely to harm your system by misuse, so if anyone else has wondered about this I suggest doing the same, or asking the wonderful folks over at the Small Basic forum.

2) Again, the small basic forum gave me the answers I needed for this one. The network class is basically used to retrieve very basic data streams over internet connections. There are two commands, Textwindow.GetWebPageContents, will retrieve the source code of a website, but not the actual web page as it seems to imply (This actually is more useful than it sounds; I do web-developing as well as programming and I often want to peruse source of a certain site for helpful bits of code without firing up firefox). DownloadFile is a mystery to me, but it has something to do getting data over networks, and I will keep trying to find something useful to do with it. Someone over at the SBF posted the source code for a Small Basic web-browser, which I couldn't make head nor tails of. Requires the FremyCompany extension library as well.

3) Turns out version 0.8 comes with a sample code that does just this, and does it well.

4) Basically, there is absolutely no straight up way to gain this kind of info, so endless googling and maybe posting a question on the SBF is the way to go. Small Basic is still a very new language (first released in 2008) but it's slowly getting more and more recognition and maybe someone out there will make a tutorial outlining these features, which I think someone will eventually. For now, I'm just learning it bit by bit with trial and error.

If anyone has any more information about these questions or has questions of their own, I might be able to tell you a thing or two. If I don't, just keep experimenting my friends.


I can't answer your questions since I didn't even know it existed until I read this quesiton but I downloaded it and I'll look at it later.

Learn it if you like it.  If you need more power you will pick another language.  Everybody always thinks whatever they are using is god's gift to mankind.

Good luck.