/
deleteListViewItem
deleteListViewItem
Description
Deletes an item from a list view user control
Functional area
User Window
Command syntax
Syntax
deleteListViewItem userControlID itemIndex or "itemString" |
Arguments
Name | Type | Required | Comments |
---|---|---|---|
userControlID | integer | yes | ID of user control item to operate on |
itemIndex | any | yes | Value can either be a string or an integer. If it is a string, all items matching the string value will be removed (i.e. multiple items may be removed). If the value is an integer, the item at the (zero-based) index will be removed. If the index is out of range (i.e. below zero or more than the number of items in the list view, the command will fail. |
Flags
None
Return value
integer
Returns the number of items left in the list view user control
Examples
// Deletes some items from a List View we created earlier. int $listViewID = `getGlobalIntVar "MyListViewID"`; // Deletes the 4th item (indices are zero-based) deleteListViewItem $listViewID 3; // Deletes all items whose first column value is "Mary" deleteListViewItem $listViewID "Mary";
Additional information
Related commands
, multiple selections available,
Related content
deleteAllListBoxItems
deleteAllListBoxItems
More like this
getNumListViewItems
getNumListViewItems
More like this
deleteAllDropListItems
deleteAllDropListItems
More like this
getListViewItemText
getListViewItemText
More like this
getListBoxItem
getListBoxItem
More like this
selectListViewItem
selectListViewItem
More like this