LWia::EnumChildItems

#include "ltwrappr.h"

virtual L_INT LWia::EnumChildItems(pWiaRootItem)

L_VOID * pWiaRootItem;

/* pointer to IWiaItem or IWiaItem2 interface */

Enumerate all available child items for the root item specified in the pWiaRootItem parameter.

Parameter

Description

pWiaRootItem

Valid pointer to a type IWiaItem or IWiaItem2 object (IWiaItem if using WIA Version 1.0; IWiaItem2 if using WIA Version 2.0), which represents the root item for which its child items are being enumerated.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

This feature is available in LEADTOOLS version 16 or higher.

The WIA run-time system represents each WIA hardware device in a hierarchical tree of IWiaItem or IWiaItem2 objects (IWiaItem objects if WIA Version 1.0 is being used; IWiaItem2 objects if WIA Version 2.0 is being used). This function enables applications to enumerate the child items for the specified root item.

You should pass a valid pWiaRootItem parameter. First you need to retrieve a pointer to the device's root Item itself by declaring a variable pointer of type IWiaItem* or IWiaItem2*. Next, pass the address of that pointer to the third parameter of the LWia::GetRootItem function (do not forget to cast it to (L_VOID**)). Then you can pass this same declared variable (after the LWia::GetRootItem function fills it with a valid item) to the LWia::EnumChildItems function as the root item for which you wish to enumerate the child items.

Required DLLs and Libraries

LTWIA

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

See Also

Functions:

LWia::GetRootItem, LWia::InitSession, LWia::EndSession, Class Members

Topics:

Managing WIA Sources

 

WIA Functionality: Property Functions

Example

For an example, refer to LWia::GetRootItem.