Set Up Useful Shortcuts in the Send To Folder
If you develop applications that use components that need to be registered, consider setting up a shortcut to regsvr32 in the “Send To” folder on a user’s machine as part
If you develop applications that use components that need to be registered, consider setting up a shortcut to regsvr32 in the “Send To” folder on a user’s machine as part
Macros in C++ are better avoided. They are unsafe, hard to debug, and may bloat your .exe files. C++ offers significantly better alternatives to them: 1. Function-like macros should be
A non-explicit constructor taking a single argument is also a conversion operator, which casts its argument to an object of the constructor’s class. When the compiler has to resolve an
When two or more classes serve as base classes in multiple inheritance, you want to choose a distinct name for each member function in order to avoid name ambiguity: class
Void * can serve as a generic data pointer, yet it suffers from the well-known ailments associated with pointers: it can be NULL or a dangling pointer. Furthermore, it usually
Like ordinary functions, templates can have default type arguments. A good example is STL’s vector. It actually has two arguments–the second one is an allocator class template. Since an allocator
To allow the user to control long operations, use a single CommandButton to control starting and stopping a looping process: Dim Running As BooleanPrivate Sub CmdStartStop_Click() If Running Then ‘
It’s fairly common practice to add buttons to your date and numeric fields to allow users to select and display a popup calendar or calculator. However, to display a calculator
The algorithm shown in the tip, “Swap Values Using Only Two Variables” [“101 Tech Tips for VB Developers, Supplement to the February 1997 issue of VBPJ, page 25], crashes not