IsObject() [v1.0.90+]
Returns a non-zero number if the specified value is an object.
Boolean := IsObject(Value)
Parameters
- Value
-
The value to check.
Return Value
This function returns 1 (true) if Value is an object, otherwise 0 (false).
Any value which is not a primitive value (number or string) is considered to be an object, including those which do not derive from Object, such as COM wrapper objects. This distinction is made because objects share several common traits in contrast to primitive values:
- Each object is dynamically allocated and reference-counted. Any number of variables, properties or array elements may refer to the same object. For immutable values this distinction isn't important, but objects can have mutable properties.
- Each object has a unique address which is also an interface pointer compatible with IDispatch.
- An object compares equal to another value only if it is the same object.
- Attempts to use an object as a primitive value typically behave as though the value is an empty string.
Objects
Examples
Reports "This is an object." because the value is an object.
object := {key: "value"}
if IsObject(object)
MsgBox, This is an object.
else
MsgBox, This is not an object.