Tip Bank

DevX - Software Development Resource

Run a VB Application During Start-up

Depending on the version of Windows targeted, there are two different ways to run a VB application during the boot process.Under Windows 9x systems, place a Shell command in the

DevX - Software Development Resource

CheckWindowsUser – Validate a username/password pair

Private Declare Function LogonUser Lib “Advapi32” Alias “LogonUserA” (ByVal _ lpszUserName As String, ByVal lpszDomain As String, _ ByVal lpszPassword As String, ByVal dwLogonType As Long, _ ByVal dwLogonProvider As

DevX - Software Development Resource

“Setter” and “Getter” Member Functions

Encapsulation is a fundamental principle in object orientation. Encapsulation restricts direct access to a data member of a class. Instead, users query the object itself in order to get or

DevX - Software Development Resource

Streams and Pointers

Look at the following program. It compiles correctly under every standard-conforming compiler. At first, this may seem surprising because seemingly, because it’s impossible delete an object which is not a

DevX - Software Development Resource

auto_ptr and Derived Objects

The auto_ptr class template respects polymorphism and destroys derived objects of base pointers properly. In the following program, an auto_ptr is actually bound to a B * pointer, where B

DevX - Software Development Resource

Qualified Calls

A function call such as the following: classname::funcname(); is a qualified call. Qualified disambiguate function names. They are needed, for instance, in a class that inherits from several base classes,

DevX - Software Development Resource

Accessing Static Class Members

Because static class members are not associated with a particular object of their class, you can access them even if you haven’t instantiated any object. In the following example, the