Visual Basic Windows API Tutorials

Sometimes you need to interface deep into the Windows operating system. Other times you need to do something Visual Basic doesn't have a built in function for. The Windows API allows you to do this. Visual Basic + API = some pretty amazing applications. Using VB and API can be a bit confusing at first, but once you understand it the sky is the limit as to what you can create.

  • Level2
    The Windows API allows any program to have full access to all the inner workings of Windows. This is means as a developer we should be learning what all the Win32 API offers so that we aren't limited by the language or libraries we are using. This tutorial walks through a simple example of how to interact with Microsoft's Windows API.
  • Level2
    Even though .NET gives us way more power than compared to the old VB6 days. At times we need to fall back to the advanced capabilities that only the Win32 API can offer. This tutorial walks through how you can declare Windows APIs and use them in your VB.NET app. It focuses primarily on some DiskSpace and File APIs but the concepts presented here can easily be built upon for any of your Windows API needs.
  • 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.
  • Level2
    This VB6 tutorial teaches you how you can use Visual Basic coupled with the Win32 API to activate the main window of a program that is running. Very useful if you want to check if a program is running or if you want to bring another program to the forefront.
  • Level3
    The Win32 API is a bit complex but very powerful. This tutorial shows you how to easily use the Windows API in a simple way. It explains the safety steps you need to take and how to write excellent API code.
  • Level2
    The PlaySound API is a simple and very useful function that allows you to play any WAV file from within your Visual Basic application. This includes playing built in Windows sounds that are set through the control panel.
  • Level2
    You can use the Windows API to move the mouse cursor around the screen. Learn how with this VB6 tutorial.
  • Level2
    Visual Basic has a built in Shell command however it is very limited. This tutorial describes how you can use the Windows API functions to create a "Super Shell". This will allow you have more advanced program launching abilities.
  • Level3
    Sub classing in Visual Basic is a very powerful concept. However, it fails when you try to implement it from within an ActiveX control. Learn how you can handle window sub classing from withing your active x controls with this tutorial.
  • 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.
  • Level2
    The Scroll Mouse (or intelli-mouse) has been around for a long time. Sometimes you might want to catch the scroll events in your application. You can do this with Windows API calls. Learn how in this VB6 tutorial.
  • Level2
    WAV format is a very common format for sound files. You can not get all the information you might want directly using Visual Basic built in commands. However, by utilizing a few Windows API calls. This tutorial shows you how you can get extended WAV info such as the bit level and format.
  • Level2
    You knew you could create database apps with VB6 but this tutorial walks you through how you can create a Visual Basic Screen Saver. The sky is the limit once you learn how to do this.
  • Level3
    Many times you want your VB6 application to interact with other dlls and applications. This can occur if you want to use one of the functions that Microsoft wrote in their Windows API Dlls or if you want to call a function written in a different language such as c or c++. To do this you need to understand how VB6 handles API's this VB tutorial explains how.
  • Level2
    Creating PDF documents in Visual Basic has always been a difficult task. Many times people have to purchase controls to do it for them. Not with this Visual Basic tutorial. PDF documents can be created in a snap using the mjwPDF class. This is the first in a series of tutorials. It covers the creation of a basic PDF document.
  • Level2
    This explains how you can declare and call Windows API functions from within your program.
  • Level3
    Games aren't much fun without collisions. Ships collide into astroids little mushrooms collide into mario. We must know how to detect these collisions - and it turns out to be pretty easy.
  • Level4
    Have you ever wanted to display your program in the system tray (next to the clock). You can buy a control to do this or you can do it yourself using Windows API calls only.
  • Level2
    A fun thing maybe a useful thing. See how in you can call a Windows API function in order to tell Windows to start the default screen saver.
  • Level3
    The FlashWindow Win32 API call allows you to do some fun things. This tutorial shows you how to declare and call it from your app.

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