JVCL Help:IJvDataConsumerViewList.SubItemIndex@IJvDataItem@Integer

From Project JEDI Wiki
Jump to navigationJump to search
JEDI Visual Component Library Help

Search in JVCL Help

 
Search in all projects
 

Summary

Retrieve the index to a child item of a given item.


Pascal

 functionSubItemIndex(Parent: IJvDataItem; Index: Integer): Integer; overload;
functionSubItemIndex(Parent: Integer; Index: Integer): Integer; overload;


Parameters

Parameters Description
Parent: IJvDataItem Either a reference to the parent item or a 0-based index in the view list of the parent item. Allowed values for the index version ranges from 0 to Count-1.
Index: Integer 0-based index of the child item to retrieve.


Description

SubItemIndex retrieves a 0-based index in the viewlist to the specified child item of the specified pare t item. The two versions of this method allow to specify the parent either as a data item or as a 0-based index in the view list. If the parent item could not be found either an exception is raised or -1 is returned (depends on the implementer). If the item has no children or the index is out of range either an exception is raised or -1 is returned (depends on the implementer). Most implementers will choose to return -1 in this case, as there's no real way to tell the number of child items an item has.


See Also

IJvDataConsumerViewList.SubItem


About

Contribute to this help topic

This documentation wiki is based on the collaborative effort of Project JEDI users. Your edits are welcome in order to improve documentation quality: edit this page