Rediger

Del via


IDeviceBroker::OpenDeviceFromInterfacePath method

Important

These interfaces are not supported and should not be used. Use the APIs in the Device Access API C++ Programming Reference instead.

Attempts to open a device interface instance on behalf of a client. IID = 8604b268-34A6-4b1A-A59F-CDBD8379FD98.

Syntax

HRESULT OpenDeviceFromInterfacePath(
  [in]  PCWSTR pszDeviceInterfacePath,
  [in]  DWORD  desiredAccess,
  [in]  DWORD  shareMode,
  [in]  DWORD  flagsAndAttributes,
  [out] Handle *phDevice
);

Parameters

pszDeviceInterfacePath [in]

Device interface instance to open.

desiredAccess [in]

Desired access to be passed to open.

shareMode [in]

Share mode to be passed to open.

flagsAndAttributes [in]

Flags and attributes to be passed to open.

*phDevice [out]

Resulting handle if open was successful.

Return value

If this function succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.