item Property

MSXML 5.0 SDK

Microsoft XML Core Services (MSXML) 5.0 for Microsoft Office - SOM Reference

item Property

Returns an ISchemaItem object, based on the index that is passed to the function. You can use this method to walk through a collection and examine properties for each item. To walk through the collection, increment the index from 0 to one less than the number returned from the length property.

The ISchemaItem.itemType property is used to obtain the object type for the items in the collection.

The appropriate interface is used to obtain further information about the items in the collection. See the table in the ISchemaItemCollection Interface topic for a list of the interfaces used.

[Script]

Implementation Syntax

var oISchemaItem = oISchemaItemCollection.item(lngIndex)

Parameters

lngIndex
A long integer. The index of the item to be retrieved.

Return Values

oISchemaItem
An ISchemaItem object. The schema item at the specified index.
[Visual Basic]

Implementation Syntax

Set oISchemaItem = oISchemaItemCollection.item(lngIndex)

Parameters

lngIndex
A long integer. The index of the item to be retrieved.

Return Values

oISchemaItem
An ISchemaItem object. The schema item at the specified index.
[C/C++]

Implementation Syntax

HRESULT get_item(
long index,
ISchemaItem** item);

Parameters

index [in]
A long integer. The index of the item to be retrieved.
item [out,retval]
An object. The schema item at the specified index.

Return Values

S_OK
The value returned if successful.
E_POINTER
The value returned if the item parameter is NULL.
E_FAIL
The value returned if the index is out of bounds.

To view reference information for Visual Basic or C/C++ only, click the Language Filter button Language Filter in the upper-left corner of the page.

See Also

ISchemaItem Interface | ISchemaItem itemType Property

Applies to: ISchemaItemCollection Interface