guiGridListSetColumnTitle | Multi Theft Auto: Wiki Skip to content

guiGridListSetColumnTitle

Client-side
Server-side
Shared

Manual Review Required

Please finish this page using the corresponding Old Wiki article. Go to Contribution guidelines for more information.


This function is used to change the column title of a gridlist column.

OOP Syntax Help! I don't understand this!

Syntax

bool guiGridListSetColumnTitle ( element guiGridlist, int columnIndex, string title )
Required Arguments
  • guiGridlist: The grid list you want to change the column title from
  • columnIndex: Column ID
  • title: The title of the column

Returns

  • bool: value

Returns true if the new title was set, or false otherwise.

Code Examples

shared
local gridlist = guiCreateGridList ( 332, 195, 286, 249, false )
local column = guiGridListAddColumn(gridlist, "title", 0.5)
addCommandHandler("setTitle",
function(cmd, title)
if title then
if column then
guiGridListSetColumnTitle(gridlist ,column, title)
outputChatBox("Column name has been successfully changed to : "..title,0,255,0)
end
else
outputChatBox("[Usage] /setTitle [title]",255,0,0)
end
end
)

See Also

GUI Functions