Create Window
Video Capture Help ] AVIFile Tutorial ] Licensing and Distribution ] Resources ] Awards ] Latest News ] Source Code ] Free Controls ]

 

CreateWindow for VB
Download (3.5k) VB source here!

This is basically a VB translation of the HelloWin program in Petzold's book Programming Windows 95. While most programmers will certainly find it more convenient to use forms, there are times when a low overhead, simple window, is necessary. This example should help you get started with using the CreateWIndowEX() API from VB when building controls, subclassing, etc...

Techniques demonstrated in this project
---------------------------------------
-Creating windows from "scratch" in VB (no forms!)
-Programming totally C-style from within VB
-Using CreateWindowEx() in VB


Useful functions in CreateWindow.bas
--------------------------------
vbWinMain() - equivalent to WinMain in C programs
WindowProc - a real Window procedure implemented totally in VB
GetFuncPtr() - a way to wrap AddressOf for use within VB



You may freely use and modify this code in your
own programs. However, you may not redistribute
this archive without permission from Ray Mercer
<raymer@shrinkwrapvb.com>

Copyright (c) 1998-2000, Ray Mercer - All Rights Reserved