IVIO_Device::get_AccessMode

This method retrieves the current access for a requested mode.

Syntax

HRESULT IVIO_Device::get_AccessMode ( DWORD dwMode, DWORD *pAccessMode );

Parameters

dwMode
[in] Specifies the type of mode that is requesting access. It is one of the following values:
VIODEVICEMODE_READ
This mode requests the device’s read access.
VIODEVICEMODE_WRITE
This mode requests the device’s write access.
pAccessMode
[out] Address to store the requested access for the requested mode. The following table shows possible values for this parameter.
Access
Value
Description
VIODEVACCESS_SHARED 0x0000 The device is currently shareable.
VIODEVACCESS_EXCLUSIVE 0x8000 The device currently has exclusive access.
VIODEVACCESS_NONE 0xFFFF There is no access for the requested mode.

Return Values

One of the values described in the following table is returned.

Value
Description
S_OK The access mode was successfully read.
E_INVALID The dwMode parameter was invalid.
E_POINTER The pAccessMode pointer is invalid.
E_UNEXPECTED An unexpected error occurred while requesting access.