Concept Framework 2.2 documentation Contents | Index

RTreeView.UpdateItem

Name Type Access Version Deprecated
UpdateItem function public version 1.0 no

Prototype:
public function UpdateItem(position, item)

Parameters:
position      the position(index as number or path as string or array) of the item to update
item      the updated item

Description:
This function updates an item at the given position. The item can be a string/number, RImage or RComboBox(for views with one column) or an array for views containing more than one column. Notice that when update an item, you must provide all the columns for multi-columns views. In addition, you should avoid the use of this function for tree/list views that have the Sorted property set to true.

Example:
	// for views with one column, update the fifth item
	TreeList.UpdateItem(5, "column");

	// for views with two columns, update the fifth item
	TreeList.UpdateItem(5,["column one","column two"]);

	// also, if you added a column as IMAGE_COLUMN
	myImage=new RImage(null);
	myImage.Filename="picture.jpg";
	TreeList.UpdateItem(5,myImage);

Returns:
This function returns -1 if the position is invalid, or the position otherwise.

Documented by Eduard Suica, generation time: Sun Jan 27 18:15:10 2013 GMT(c)2013 Devronium Applications