Home

DISPIDVALUE

DISPIDVALUE, more commonly written as DISPID_VALUE, is a predefined dispatch identifier used in Component Object Model (COM) automation to refer to an object's default member. It is defined in the OLE Automation headers with a value of 0 and is part of the IDispatch interface mechanism that enables late binding and scripting languages to interact with COM objects.

In practice, DISPID_VALUE identifies the default property or method of an automation-compatible object. When calling IDispatch::Invoke,

Not all COM objects expose a default member. If an object does not implement a default property

Implementation and usage notes: DISPID_VALUE is defined in standard headers (for example, OleAuto.h) and can be

In summary, DISPID_VALUE serves as the canonical identifier for a COM object's default member, enabling a uniform

a
caller
can
pass
DISPID_VALUE
as
the
dispIdMember
parameter
to
invoke
the
object's
default
member
rather
than
a
specifically
named
one.
This
is
particularly
relevant
in
environments
that
rely
on
late
binding
or
default
properties,
such
as
certain
scripting
languages.
or
method,
attempting
to
invoke
DISPID_VALUE
may
result
in
an
error
such
as
DISP_E_MEMBERNOTFOUND.
Conversely,
objects
that
do
expose
a
default
member
will
route
the
invocation
to
that
member.
used
from
languages
that
interoperate
with
COM,
including
C/C++.
It
remains
distinct
from
other
standard
DISPIDs,
such
as
DISPID_PROPERTYPUT
(used
for
setting
properties)
and
various
library-specific
DISPIDs
that
map
to
named
members.
way
to
access
that
member
through
IDispatch::Invoke
in
environments
that
use
late
binding.