ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Client functions
  3. guiSetText

Function

guiSetText

ClientInterface (GUI)Identical to MTA:SA

Changes a control's text.

Syntax

bool guiSetText(element guiElement, string text)

Arguments

guiElementelement
The control.
textstring
New text.

Returns

true on success.

Example

setTimer(function()
    local now = getRealTime()
    guiSetText(clockLabel, ("%02d:%02d"):format(now.hour, now.minute))
end, 1000, 0)