Scripting/Client/GUI/list.InsertItem
Inserts a row before row index (index = ItemCount appends). The selection moves with its row.
Syntax
list.InsertItem(index, text)Arguments
- int index – Inserts a row before row
index(index= ItemCount appends). - string text
Returns
bool
Example
function onScriptLoad()
{
// list is a list handle (see List boxes and dropdown boxes)
local result = list.InsertItem( 0, "Hello world" );
MessagePlayer( "list.InsertItem returned: " + result, player );
}This sample was generated from the signature – adapt the values to your gamemode.
Related pages
Section: List boxes and dropdown boxes
Categories: Client functions | List boxes and dropdown boxes