Search notes:

VBA: Datatype Object

A VBA object consists of the following members:
An object represents an IDispatch interface.
There is one object literal identifier: nothing.
An object variable is considered to be nothing if its reference count is 0. In such cases, objPtr returns 0.
Each object is identified by a value whose value type is object reference.
The pointer to the IUnknown interface is returned by the objPtr function.
obj = val assigns a new value to an object's default attribute. In order to change the object that the reference obj refers to, the set statement must be used, see difference between set obj = … and obj = ….

TODO

As per Don Box's Advanced Visual Basic 6, an instance of an object requires (at least) 96 bytes.
The first four (32 Bit Windows?) seem to store a pointer to a virtual table (IUnknown).
The next four (32 Bit Windows?) seem to store the reference count for that object (See the reference counting test).

See also

Functions createObject, typeOf … is, callByName and and objPtr
The new operator.
classes
datatypes
The me keyword evaluates to the respective object in a member procedure/function.

Index