Platform SDK: DirectX

DirectInputDevice.SetCommonDataFormat

The DirectInputDevice.SetCommonDataFormat method sets the input data format for standard devices.

object.SetCommonDataFormat( _
  format As CONST_DICOMMONDATAFORMATS)

Parameters

object
Object expression that resolves to a DirectInputDevice object.
format
One of the CONST_DICOMMONDATAFORMATS enumeration, identifying the data format to use for the device.

Error Codes

If the method fails, an error is raised and Err.Number may be one of the following error codes:

DIERR_ACQUIRED
DIERR_INVALIDPARAM

Remarks

The data format must be set before the device can be acquired by using the DirectInputDevice.Acquire method. It is necessary to set the data format only once. The data format cannot be changed while the device is acquired.

See Also

DirectInputDevice.SetDataFormat