|Products Purchase Publishing Articles Support Company Contact|
Products > Books > COM > Developing COM/ActiveX Components with VB6 > Introduction
Visual Basic Programmer's Guide to the Win32 API
Exploring VB6 (series)
Developing COM/ActiveX Components with VB6: A Guide to the Perplexed
What's New from the VB 5.0 edition
Win32 API Puzzle Book and Tutorial
NT Security Programming with Visual Basic 6
Visual Basic Programmer's Guide to the Windows 16 bit API
Note: This page describes a legacy product or book. The page is available for archival purposes and as a courtesy to those who have linked to it, but is no longer being updated or maintained.
Developing COM/ActiveX Components with VB6: A Guide to the Perplexed
Contact Desaware directly to purchase the eBook edition.
I've been waiting to write a book on COM/ActiveX technology for years.
True, it didn't used to be called ActiveX. Perhaps it was called OLE, or OLE Controls, or VBX, or Visual Basic Custom Controls. It doesn't matter. All along I've been working with the technology as it evolved and waiting for the right time to do a book on the subject. I was waiting for Visual Basic to mature to the point where it could be used to create these types of controls.
When I saw the beta for Visual Basic 5, I knew that my wait was over. Which left me with a problem. How do I write a book on this technology that will be both incredibly useful to Visual Basic programmers and also stand out from the myriad of ActiveX VB books that undoubtedly will appear on the bookshelves at the same time? How do I write a book detailed enough for the advanced programmer, but with enough scope to welcome even a beginning Visual Basic programmer to ActiveX development?
So I put on my "programmer" hat and thought about the things that I like and hate about technology books, and quickly realized this:
I hate manual rehashes.
Simply paraphrasing the Microsoft documentation is pointless. A certain amount of that is inevitable, I suppose, but at least an author should add a significant amount of new material-and perhaps a creative new way of looking at the technology that does not echo the manuals. I also hate having to read through things I know to find a few tidbits of new information. You know the kind of book I'm talking about, where a supposedly advanced book starts out by explaining how to draw controls on forms, click a mouse, and turn on the computer.
I knew I wanted to do a comprehensive book on ActiveX and object programming using Visual Basic. I knew I did not want to waste a lot of time rehashing the manual. In fact, I'll let you in on a little secret: The Visual Basic Documentation is not bad at all. I suppose that is an odd thing for an aftermarket book author to say.
I realized as I was reading the VB documentation that it would be perfect.
As I realized these things this, I knew what I wanted to do. I did not want to write The ActiveX Bible for Visual Basic. Microsoft already wrote it; it's in the documentation. I wanted to write the commentary!
A Talmudic Sage named Maimomides wrote the original Guide to the Perplexed in the Middle Ages. It was a guide that did not try to replace the scripture, but rather elaborate on it, interpret it, and help ordinary people understand it. While I'm certainly not a sage of his caliber, I know he had the right idea.
"So what's in this book?" you may ask. Here are some of the goals I reached for and philosophies I followed while writing it.
There are certain core concepts a programmer must understand to write ActiveX components (not to mention to program in Visual Basic in the first place). I wanted to take a step back and cover those concepts in depth. I wanted to cover them in such a way that even a beginning VB programmer could understand them. This was my task in Part 1.
On My Target Audience
I focused on information that relates to the COM-based features in recent versions of Visual Basic. If you are completely new to Visual Basic, this is probably not the book to start with, because I assume you already know how to use Visual Basic and are familiar with the general syntax of the language.
However, this book is definitely intended for people who have not yet made extensive use of the new object-oriented constructs introduced with Visual Basic 4.0 (such as classes). It is also for those who have not yet worked with OLE or COM/ActiveX technology.
I assume that you have access to the Visual Basic documentation. This book is intended to supplement the Microsoft documentation, not replace it. While there is some overlap by necessity, the emphasis is always to go beyond the documentation in the following ways:
Interpretation, clarifying those subjects that are unclear. Translating them into something that resembles English when necessary.
Illustration, adding new examples where appropriate. Showing alternate ways to implement certain features. Showing how things crash if you do them incorrectly.
Elaboration, demonstrating techniques that are not covered in the documentation. Explaining how some of the technology works behind the scenes.
Commentary, discussing not just how you can program, but how you should program. Explaining why some things are done the way that they are, and otherwise adding my two cents into the fray.
The entire book is written just like this introduction-in the first person. A commentary is, by definition, more than just an authoritative presentation of accurate technical information. It also includes interpretation and opinion. So, while I'll certainly make every effort to make sure that this book is technically accurate and reasonably comprehensive, there will be portions of the book that are based on personal opinion and biases. In other words, not only will I tell you about a feature, how it works and why. I might also tell you what I think of it, and whether you should use it or perhaps try a different approach.
If you find any technical inaccuracies, I will welcome e-mail on the subject (firstname.lastname@example.org) and make corrections promptly for the next edition, as well as post the correction on our Web site at http://www.desaware.com . If you disagree with my interpretation or commentary, I will also welcome e-mail on the subject, will read it carefully and will either post the opposing viewpoint, or delete the message -- depending on the nature of your message and my personal whim.
You've probably noticed that Visual Basic is enormous. It has evolved dramatically from version 1.0 in both size and scope. In order to make it possible to come out with a good ActiveX book in a timely manner, I had to decide how much information to cover. I have no doubt that I will receive many e-mail messages complaining that I left out that "one crucial subject" that is needed to make the book perfect. So let me start by telling you what I included and what I left out and why.