Microsoft DirectX 8.0 (Visual Basic)

DirectInputDeviceObjectInstance.GetType

Retrieves the type and instance identifier of the object.

object.GetType() As Long

Parts

object
Resolves to a DirectInputDeviceObjectInstance object.

Return Values

Returns the device type that describes the object. This value is a combination of CONST_DIDFTFLAGS flags that describe the object type (axis, button, and so forth) and contains the object instance number in the middle 16 bits.

Error Codes

If the method fails, an error is raised and Err.Number is set.

Remarks

To extract the object instance ID, use the following operation:

Dim ObjID as Long
ObjID = (diObj.GetType And &HFFFF00) \ 256