相关文章推荐
沉稳的冰棍  ·  C + + calling the ...·  昨天    · 
谦虚好学的脸盆  ·  Java8新特性 - ...·  昨天    · 
留胡子的扁豆  ·  sql ...·  昨天    · 
英勇无比的石榴  ·  java调用执行cmd命令 - ...·  21 小时前    · 
失落的饭卡  ·  uniapp得到base64 - CSDN文库·  4 月前    · 
仗义的莲藕  ·  DataGrip - 知乎·  1 年前    · 
魁梧的八宝粥  ·  laravel 多个 orderBy ...·  1 年前    · 
大力的松鼠  ·  Spring Aop 错误之:No ...·  1 年前    · 

This browser is no longer supported.

Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.

Download Microsoft Edge More info about Internet Explorer and Microsoft Edge

The HidD_GetManufacturerString routine returns a top-level collection's embedded string that identifies the manufacturer.

Syntax

BOOLEAN HidD_GetManufacturerString(
  [in]  HANDLE HidDeviceObject,
  [out] PVOID  Buffer,
  [in]  ULONG  BufferLength

Parameters

[in] HidDeviceObject

Specifies an open handle to a top-level collection.

[out] Buffer

Pointer to a caller-allocated buffer that the routine uses to return the collection's manufacturer string. The routine returns a NULL-terminated wide character string in a human-readable format.

[in] BufferLength

Specifies the length, in bytes, of a caller-allocated buffer provided at Buffer. If the buffer is not large enough to return the entire NULL-terminated embedded string, the routine returns nothing in the buffer. The supplied buffer must be <= 4093 bytes (2^12 – 3).

Return value

HidD_HidD_GetManufacturerString returns TRUE if it returns the entire NULL-terminated embedded string. Otherwise, the routine returns FALSE. Use GetLastError to get extended error information.

Remarks

Only user-mode applications can call HidD_GetManufacturerString. Kernel-mode drivers can use an IOCTL_HID_GET_MANUFACTURER_STRING request.

The maximum possible number of characters in an embedded string is device specific. For USB devices, the maximum string length is 126 wide characters (not including the terminating NULL character).

If the supplied buffer is not <= 4093 bytes (2^12 – 3) the call may fail (depending on the underlying protocol, HID/Bluetooth/SPI) with error code ERROR_GEN_FAILURE (0x0000001f).

For more information see HID Collections.

Requirements

IOCTL_HID_GET_INDEXED_STRING

IOCTL_HID_GET_MANUFACTURER_STRING

IOCTL_HID_GET_PRODUCT_STRING

IOCTL_HID_GET_SERIALNUMBER_STRING