In the following section, you can find a variety of Visual Basic code samples.
For every sample, you can download the entire project for opening in Visual Basic 6.0.
Revealing the passwords behind asterisks in Internet Explorer|
This small utility reveals the passwords stored behind the asterisks in the web pages of Internet Explorer 5.0 and above.
Creating a real console application in Visual Basic !|
Although the Visual Basic compiler doesn't allow officially to create console applications,
it's possible to do it with a simple trick.
Read more >>
Revealing the passwords behind asterisks|
This code snippet scans all opened windows, and reveals the passwords
behind the password text-boxes.
Access 95/97 Password Revealer|
This small utility reveals the database password of Microsoft Access files.
It works only with version 95 and 97 of Microsoft Access.
System resources in Windows 95/98|
This code snippet shows the percentages of free system resources in Windows 95 and Windows 98.
Fast string concatenation|
With this class, you can concatenate small strings into one big string in faster way than the standard "&" operator.
Using bidi32.dll for Logical-Visual conversion|
This code snippet is designated for using in bidirectional systems only (Hebrew and Arabic).
It uses the functions in bidi32.dll to convert strings from Visual to Logical and from Logical to Visual.
Painting a Gradient between 2 colors on a form|
This code snippet shows how to paint a gradient on a form using Win32 API.
Drawing a rotated text on a form|
This code snippet demonstrate how to draw a rotated text on a form.
Creating a circle shaped window|
This code snippet demonstrates how to create a circle shaped window, by using a few Win32 API calls.
Web client tester|
With this small utility, you can send HTTP queries and see how the servers responds to those queries.
Faster items adding in ComboBox|
This code snippet shows you how to add combo items with Win32 API. It's much faster than using the AddItem method of VB.
Faster items adding in ComboBox (with item data)|
This code snippet shows you how to add combo items (both strings and items data) with Win32 API. It's much faster than using the AddItem method of VB.
Executing Control Panel applets|
This code snippet shows how to run standard Control Panel applets (Display Properties, Reginal Settings, Mouse Properties, and more)
from Visual Basic code.
Converting network drive-based path to universal path name|
This code snippet shows how to use the WNetGetUniversalName for converting
network drive-based path (Like I:\windows) to universal path name (Like \\MyComputer\c\windows)
Opening special Explorer windows|
This code snippet shows you how to open special Explorer windows, like My Computer, Control Panel, Printers, Fonts and more...
DoEvents alternative function|
This code snippet shows how to create an alternative function for the standard DoEvents function.
Registering and using a new window class|
This code snippet shows you how to register a new window class in Visual Basic and
use that class to create new windows, and show them on a form.
Displaying and using a dialog box from external DLL file|
This code sample shows you how to display a dialog box from external DLL file.
In this sample, the standard "Run" dialog of Microsoft Windows is shown on the screen.
Displaying the "Shut Down Windows" dialog|
This code snippet displays the "Shut Down Windows" by using undocumented API in shell32.dll
Getting the filename of an ActiveX class name|