Predefined Constants

Predefined Constants

The constants below are defined by this extension, and will only be available when the extension has either been compiled into PHP or dynamically loaded at runtime.

COM constants
Constant Value Description Notes
CLSCTX_INPROC_SERVER (integer) 1 The code that creates and manages objects of this class is a DLL that runs in the same process as the caller of the function specifying the class context.  
CLSCTX_INPROC_HANDLER (integer) 2 The code that manages objects of this class is an in-process handler. This is a DLL that runs in the client process and implements client-side structures of this class when instances of the class are accessed remotely.  
CLSCTX_LOCAL_SERVER (integer) 4 The EXE code that creates and manages objects of this class runs on same machine but is loaded in a separate process space.  
CLSCTX_REMOTE_SERVER (integer) 16 A remote context. The code that creates and manages objects of this class is run on a different computer.  
CLSCTX_SERVER (integer) 21 Indicates server code, whether in-process, local, or remote. This definition ORs CLSCTX_INPROC_SERVER, CLSCTX_LOCAL_SERVER, and CLSCTX_REMOTE_SERVER.  
CLSCTX_ALL (integer) 23 Indicates all class contexts. This definition ORs CLSCTX_INPROC_HANDLER and CLSCTX_SERVER.  
VT_NULL (integer) 1 NULL pointer reference.  
VT_EMPTY (integer) 0 A property with a type indicator of VT_EMPTY has no data associated with it; that is, the size of the value is zero.  
VT_UI1 (integer) 17 1-byte unsigned integer.  
VT_I2 (integer) 2 Two bytes representing a 2-byte signed integer value.  
VT_I4 (integer) 3 4-byte signed integer value.  
VT_R4 (integer) 4 32-bit IEEE floating point value.  
VT_R8 (integer) 5 64-bit IEEE floating point value.  
VT_BOOL (integer) 11 Boolean value.  
VT_ERROR (integer) 10 Error code; containing the status code associated with the error.  
VT_CY (integer) 6 8-byte two's complement integer (scaled by 10,000).  
VT_DATE (integer) 7 A 64-bit floating point number representing the number of days (not seconds) since December 31, 1899. For example, January 1, 1900, is 2.0, January 2, 1900, is 3.0, and so on). This is stored in the same representation as VT_R8.  
VT_BSTR (integer) 8 Pointer to a null-terminated Unicode string.  
VT_DECIMAL (integer) 14 A decimal structure.  
VT_UNKNOWN (integer) 13 A pointer to an object that implements the IUnknown interface.  
VT_DISPATCH (integer) 9 A pointer to a pointer to an object was specified.  
VT_VARIANT (integer) 12 A type indicator followed by the corresponding value. VT_VARIANT can be used only with VT_BYREF.  
VT_I1 (integer) 16 1-byte signed integer.  
VT_UI2 (integer) 18 2-byte unsigned integer.  
VT_UI4 (integer) 19 4-byte unsigned integer.  
VT_INT (integer) 22 4-byte signed integer value (equivalent to VT_I4).  
VT_UINT (integer) 23 4-byte unsigned integer (equivalent to VT_UI4).  
VT_ARRAY (integer) 8192 If the type indicator is combined with VT_ARRAY by an OR operator, the value is a pointer to a SAFEARRAY. VT_ARRAY can use the OR with the following data types: VT_I1, VT_UI1, VT_I2, VT_UI2, VT_I4, VT_UI4, VT_INT, VT_UINT, VT_R4, VT_R8, VT_BOOL, VT_DECIMAL, VT_ERROR, VT_CY, VT_DATE, VT_BSTR, VT_DISPATCH, VT_UNKNOWN and VT_VARIANT.  
VT_BYREF (integer) 16384 If the type indicator is combined with VT_BYREF by an OR operator, the value is a reference. Reference types are interpreted as a reference to data, similar to the reference type in C++.  
CP_ACP (integer) 0 Default to ANSI code page.  
CP_MACCP (integer) 2 Macintosh code page.  
CP_OEMCP (integer) 1 Default to OEM code page.  
CP_UTF7 (integer) 65000 Unicode (UTF-7).  
CP_UTF8 (integer) 65001 Unicode (UTF-8).  
CP_SYMBOL (integer) 42 SYMBOL translations.  
CP_THREAD_ACP (integer) 3 Current thread's ANSI code page  
VARCMP_LT (integer) 0 The left bstr is less than right bstr.  
VARCMP_EQ (integer) 1 The two parameters are equal.  
VARCMP_GT (integer) 2 The left bstr is greater than right bstr.  
VARCMP_NULL (integer) 3 Either expression is NULL.  
NORM_IGNORECASE (integer) 1 Ignore case sensitivity.  
NORM_IGNORENONSPACE (integer) 2 Ignore nonspacing characters.  
NORM_IGNORESYMBOLS (integer) 4 Ignore symbols.  
NORM_IGNOREWIDTH (integer) 131072 Ignore string width.  
NORM_IGNOREKANATYPE (integer) 65536 Ignore Kana type.  
NORM_IGNOREKASHIDA (integer) 262144 Ignore Arabic kashida characters. Availability is dependent upon under lying library.
DISP_E_DIVBYZERO (integer) -2147352558 A return error that indicates a divide by zero error.  
DISP_E_OVERFLOW (integer) -2147352566 An error that indicates that a value could not be coerced to its expected representation.  
MK_E_UNAVAILABLE (integer) -2147221021 iMoniker COM status code, return on errors where the function call failed due to unavailability.  

Customers Area | Contact us | Affiliates