GuiGridListSetSelectedItem: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 15: Line 15:
==Optional Arguments==
==Optional Arguments==
{{OptionalArg}}
{{OptionalArg}}
*'''bReset:'''
*'''bReset:''' set to false for multiple selections
}}
}}



Revision as of 12:13, 13 September 2011

This function selects an item from a gridlist. If you wish to deselect whatever item is selected, pass 0 as both the rowIndex and columnIndex arguments.

Syntax

bool guiGridListSetSelectedItem ( element gridList, int rowIndex, int columnIndex [, bool bReset = true ] )

Required Arguments

  • gridList: the grid list you want to select an item from
  • rowIndex: the row you want to select (index 0 is the first row)
  • columnIndex: the column you want to select (index 1 is the first column)

Optional Arguments

NOTE: When using optional arguments, you might need to supply all arguments before the one you wish to use. For more information on optional arguments, see optional arguments.

  • bReset: set to false for multiple selections

Returns

Returns true if the passed arguments are correct and the item has been selected, false otherwise.

Example

guiGridListSetSelectedItem ( spawnScreenGridList, 0, 0) -- resets selection to zero

See Also

General functions

Browsers

Buttons

Checkboxes

Comboboxes

Edit Boxes

Gridlists

Memos

Progressbars

Radio Buttons

Scrollbars

Scrollpanes

Static Images

Tab Panels

Tabs

Text Labels

Windows