Visual Basic Simple Functions Tutorials

Every complex program is made up of many, many, many simple functions. If you want to create a full application you must start by understanding some key simple Visual Basic functions. Once you understand these, you can put them all together to create the next killer VB6 app.

  • Level1
    Once you start developing even the most basic of desktop applications you will hit a point where you need to save data out to a file. The simplest way to do this is to simply save it out into a text file (if you want to get more advanced you can encrypt it). This tutorial gives you the understanding you need to save data out into a simple text format.
  • Level1
    So you have a file full of text how can you parse and read it. This File Reading VB.NET tutorial explains exactly how. It goes over examples of fixed width files, tab and comma delimited files, and even how to use the .NET TextFieldParser class. After going through these examples you will be handling text files with the best of them.
  • Level1
    Comparisons in programming allow us to do the most simple and powerful thing - make a choice. By using comparisons we can do things like branch in different directions if something is true, or loop over a bunch of things until a comparison is false, etc. This tutorial explains all the operations VB.NET supports when doing comparisons. This will provide a solid foundation for some of the more advanced features of Visual Basic .NET.
  • Level1
    VB.NET has amazing support for handling strings. This includes both the native .NET methods as well as the ones in Microsoft provided Microsoft.VisualBasic namespace (which makes migrating from VB6 over to VB.NET much easier). This tutorial goes through most of the string handling functions in in both these areas and compares them to each other.
  • Level2
    For everyone coming from a VB6 background Microsoft has provided many great ways to migrate over to VB.NET. One stepping stone in this process is the Microsoft.VisualBasic namespace that they provided. This namespace allows VB6 programmers to start developing VB.NET apps quickly and comfortably. This tutorial gives a quick introduction to this namespace and how you can use it to start developing in VB.NET and then move onto the more “pure” .NET functions.
  • Level1
    As you put together great applications you will find there are certain controls that you will use over and over again. It is important to get a good foundation in how you can use these controls, what functionality they offer, and what their limitations are. This tutorial provides just that foundation.
  • Level1
    What day is it? What time is it? VB.NET provides great support for both dates and DateTimes. With the DateTime structure you can format dates and times to be displayed in different ways and you can add time to an existing date or time. See how long apart two dates are. And many more things (all in an object oriented way).
  • Level1

    When developing great applications you almost always need to keep track of lists of data. The VB.NET structure to handle this is the array. In this tutorial we look at arrays - how to create them, modify them, iterate over them, etc.

  • Level2
    You will find times that you need to interact with other programs code through DLLs. These can be DLLs written by yourself or others. The most common time you do this is with the Windows API. This tutorial explains how you can convert C style strings like the Win32 API uses into VB strings.
  • Level1
    Errors happen. This is how programming works. Your goal is to handle runtime errors in a graceful way. At times this means simply displaying them to the end user in a pretty way. Other times you have to handle them yourself. Learn how with this Visual Basic tutorial.
  • Level1
    Visual Basic allows you to easily create event driven applications. Depending on your background this might be very new for you to understand. This tutorial shows you exactly how to begin as an event driven programmer.
  • Level1
    When interfacing with the Windows API from within Visual Basic you many times get return values that are made up of complex data types. C has built in functions to handle these but you need to write your own in VB6. Learn how with this Visual Basic tutorial.
  • Level1
    Subroutines and functions allow you to break your program up into smaller and more manageable chunks. You will use both of these many times when you develop VB applications you must learn them well.
  • Level1
    There is only one very important time to use the GoTo statement in error handling. You almost never need to use the GoSub function but this tutorial explains it in case you see it in other peoples code.
  • Level1
    Many times when programming you will need to join strings together or a string with some other data type such as a currency or a number. This tutorial explains how to properly do this in Visual Basic 6 using the & (ampersand) or plus operator.
  • Level1
    VB's arithmetic operators allow you to actually do things with numbers. You have all the basics (like you'd find on your calculator) plus many more advanced operators at your disposal.
  • Level1
    In VB assignments are very easy to use. However, this tutorial explains all the details of what VB does when you use the simple = statement and gives examples of valid and invalid assignments.
  • Level1
    This is another program that says hello to the world. However, it uses a few more controls and says hello in a bit of a fancier way. Learn how to write a simple VB6 app using command buttons and label controls with this VB tutorial.
  • Level3
    The VB6 File System Object (FSO) allows you to do many things that aren't built into the normal VB commands. With the FSO you can do all sorts of file and folder manipulation, querying, reading, writing, and many many other things.
  • Level2
    Visual Basic has many built in functions that allow you to manipulate files, directories, and other file system properties. This VB tutorial shows how you can use these functions to manipulate and change Window's file system objects.
  • Level2
    Random Access files allow you to read from a specified area of the file with out having to read everything before it. This works great if you want to read the 50th record of your data with out reading all 49 records before it. Check out how to do this in this Random Access VB tutorial.
  • Level2
    If a file doesn't have a standard text format you will need to read and write to it using VB's binary functions. This works well for files such as pictures, zip files, exe's, and other resource files that aren't just text. Learn how to manipulate binary files in this VB6 tutorial.
  • Level2
    Many times you need to write data from your VB application to a file. This tutorial explains how you can use the Write # and Print # commands to write out your variables into a sequential file.
  • Level2
    Many times you need to read a file that has each field a fixed width. This can be used to keep track of data (like a poor mans database) or if you are reading in a file that a different program printed out.
  • Level2
    Once you start learning how to create even slightly complex VB programs you will inevitably need to implement some basic error handling. This allows you to capture errors and handle them in a graceful way instead of having your fancy Visual Basic application crash and burn.
  • Level2
    Many times, when programming, you need to know how to sort a bunch of items. One of the easiest ways to do this is to use an array and some of the built in VB6 functions. This Visual Basic tutorial shows you exactly how to do this!
  • Level2
    This VB6 tutorial explains how you can easily search an array in Visual Basic. It gives examples of both serial (or linear) searches and binary searches.
  • Level3
    This VB6 tutorial demonstrates how you can pass arrays to functions, how User Defined Type (UDT) arrays work, and how variant arrays work. It is a little more advanced then the beginner tutorial but is still very easy to follow.
  • Level2
    When writing a program you will often need to do something repeatedly. Visual Basic makes this very easy using different kinds of loops. This tutorial focuses on VB6's Do, While, and For loops.
  • Level2
    Selection statements in VB6 allow you to branch based on conditions. Use the Visual Basic if, else, and select statements.
  • Level2
    Understanding conditional statements are a necessity if you are going to write any sort of real world applications. This tutorial walks you through it.
  • Level2
    Visual Basic has a few built in string array functions including Split, Join, and Filter. This VB tutorial explains how to use them.
  • Level2
    This tutorial explains all the main vb6 string functions that allow you to manipulate strings including the Len, Mid, Left, Right, UCase, LCase, Instr, InstrRev, String, Space, Replace, StrReverse, LTrim, RTrim, Trim, Asc, Chr, and the ASCII table. This Visual Basic tutorial should meet all your needs.
  • Level2
    This Visual Basic Tutorial explains how you can format Numbers, Currency, and percents using VB6 Format functions.
  • Level1
    Custom string formatting can be accomplished in Visual Basic using specific characters recognized by the Format function. This VB6 tutorial explains how.
  • Level1
    This VB6 tutorial explains how you can format dates and times using the Visual Basic format command.
  • Level1
    The VB6 Format function can be used to format numeric, date, time, and string data. This Visual Basic tutorial explains exactly how this can be done using Custom Numeric Formats.
  • Level1
    The VB6 Format function can be used to format numeric, date, time, and string data. This Visual Basic tutorial explains exactly how this can be done using Named Formats.

If you enjoyed this post, subscribe for updates (it's free)