IEnumWIA_DEV_CAPS::Next method (wia_xp.h)
The IEnumWIA_DEV_CAPS::Next method fills an array of pointers to WIA_DEV_CAP structures.
Syntax
HRESULT Next(
[in] ULONG celt,
[out] WIA_DEV_CAP *rgelt,
[in, out] ULONG *pceltFetched
);
Parameters
[in] celt
Type: ULONG
Specifies the number of array elements in the array indicated by the rgelt parameter.
[out] rgelt
Type: WIA_DEV_CAP*
Pointer to an array of WIA_DEV_CAP structures. IEnumWIA_DEV_CAPS::Next fills this array of structures.
[in, out] pceltFetched
Type: ULONG*
On output, this parameter contains the number of structure pointers actually stored in the array indicated by the rgelt parameter.
Return value
Type: HRESULT
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
Remarks
Applications use this method to query the capabilities of each available Windows Image Acquisition (WIA) hardware device. To do so, the application passes a pointer to an array of WIA_DEV_CAP structures that it allocates. It also passes in the number of array elements in the parameter celt. The IEnumWIA_DEV_CAPS::Next method fills the array with structures. Applications then use the structures to enumerate WIA hardware device capabilities.
WIA device capabilities are defined as events and commands that the device supports. Using the rgelt array, IEnumWIA_DEV_CAPS::Next passes a single structure to the application for each event and command that the device supports.
Note that IEnumWIA_DEV_CAPS::Next dynamically allocates the WIA_DEV_CAP structures it provides to applications. Therefore, applications must delete the WIA_DEV_CAP structures they receive through the rgelt parameter. Applications should use SysFreeString to free the bstrName, bstrDescription, and bstrIcon fields of all WIA_DEV_CAP structures.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 2000 Professional, Windows XP [desktop apps only] |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Target Platform | Windows |
Header | wia_xp.h (include Wia.h) |
Library | Wiaguid.lib |