Skip to content

SetGadgetText

Narta Xaymar Dirks edited this page Oct 28, 2026 · 5 revisions
BlitzPlus

SetGadgetText

SetGadgetText:Void gadget:Int32, text:String
Parameter Mode Type Default Description
gadget In Int32 required Handle of a gadget that has text.
text In String required The new text.

Description

Changes the text of a gadget, like the caption of a button or label or the title of a window. Text fields and text areas have commands of their own, but this works on them too.

Examples

Graphics 320, 240, 32, 2
win = CreateWindow("Text", 10, 10, 300, 100, Desktop(), 3)
lab = CreateLabel("Before", 10, 10, 200, 24, win)
SetGadgetText lab, "After"
Repeat
Until WaitEvent() = $803

Related Commands

GadgetItemText, GadgetText, SetButtonState, SetGadgetFont, SetGadgetLayout, SetGadgetShape, SetPanelColor, SetPanelImage

Home · Command Index



Differences
Language Features
BlitzBasic
Blitz3D
BlitzPlus

Clone this wiki locally