Name
Listview.Rename -- rename an entry
Synopsis
moai.DoMethod(id, "Rename", pos, [icon1,] column1$, ...)
Function
Rename the listview entry at the specified position. If the listview has multiple columns, you need to pass a new name for every column. It is not possible to rename only a single column entry - this method always affects the complete row so you need to pass as many strings as there are columns in your listview.

For all columns that have the Listviewcolumn.Icon attribute set, you also need to pass an icon before the actual text. The icon has to be an identifier of a Hollywood brush/icon which should be used as the icon for the column. If Listviewcolumn.Icon isn't set, then you must omit the icon parameter and only pass text data for the listview entry. If you've set Listviewcolumn.Icon to True and you don't want to show an icon in this particular row and column, you can also pass the special value -1. In that case, RapaGUI won't show an icon even though Listviewcolumn.Icon has been set to True. Please note that auto-generated IDs cannot be used. Please also read about RapaGUI's image cache to learn more about icon support in RapaGUI. See Image cache for details.

In case a column is showing a checkbox, you have to pass "On", "True", or "1" to select the checkbox and any other text to deselect the checkbox.

The entry position is specified in the pos argument. This can be an absolute index position starting at 0 for the first entry or one of the following special values:

Active
Rename the active entry.

Note that on AmigaOS and compatibles icon support is only available with MUI 4.0 or better.

Inputs
id
id of the listview object
pos
entry position as absolute number or special value (see above)
icon1
optional: icon for the first column; this must only be passed if the column has the icon attribute set; note that this must be a numeric identifier and auto-generated IDs are not valid in this case
column1$
new text for entry in the first column
...
more entries if listview has multiple columns

Show TOC