Difference between revisions of "Code samples"
From HashVB
(test) |
m (Reverted edit of 221.67.137.31, changed back to last version by Wakjah) |
||
Line 32: | Line 32: | ||
* [http://www.visualbasicforum.com/showthread.php?t=129548 BitBlt] | * [http://www.visualbasicforum.com/showthread.php?t=129548 BitBlt] | ||
− | ===Look & | + | ===Look & Feel=== |
* [[XP style|XP Styles in your application]] | * [[XP style|XP Styles in your application]] | ||
* [[Creating Transparent Controls (.NET)|Creating a transparent control in .NET]] | * [[Creating Transparent Controls (.NET)|Creating a transparent control in .NET]] | ||
Line 63: | Line 63: | ||
* [[Windows version|Detecting the version of Windows]] | * [[Windows version|Detecting the version of Windows]] | ||
* [[Close_Without_End|How to close your app without using End]] | * [[Close_Without_End|How to close your app without using End]] | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− |
Revision as of 13:49, 8 March 2006
Below are a selection of VB code samples. Feel free to use any of them in your own projects.
Contents
COM objects
- Firing events in an object from a code module
- Modularised Subclassing using interfaces and CopyMemory
- Creating singleton objects
File handling
- File I/O. Reliably
- Getting special folder paths
- How to iterate through a directory structure using APIs
- Working with INI files in .NET
Networking
- How to get a list of the network adapters on the system
- Enumerating the IP addresses allocated to the local machine
Strings
User interface
- Creating and using control arrays
- How to Catch Mouse Hover and Out Events
- How to catch KeyPresses on a form when a control has focus
Graphics
- Introduction to GDI drawing
- Drawing with a backbuffer
- How to draw an image to a DC with GDI
- All about StretchBlt
- Pattern Brushes
- BitBlt
Look & Feel
- XP Styles in your application
- Creating a transparent control in .NET
- Using Tab controls in your applications
Text boxes
List boxes
Windows
- Making a window "Always on top"
- Dragging windows/controls the easy way
- How to create a tool window that floats above your app
- How to subclass a window to catch useful windows messages in VB6 and in VB.NET
- Modularised Subclassing using interfaces and CopyMemory
Variables
- How do you tell if a number is an integer?
- Obtain the type name for a variable
- Pass a user defined type to a class
- Pointers and CopyMemory