UIText() - Dynamic Text Update Command

This function will update the text on a UI button on the PDTS touchscreen.
You specify the button ID and the text you wish to appear on it. This function can reside on the PDTS or on a remote device.
If the text string is too long to fit on the button it will center it and display as much as it can.

Currently this command does not work on the Antumbra or Revoultion Display units as of April 2026.

Syntax

UIText(ButtonId=x,DestDeviceCode=y,DestBoxNumber=z,TextMessage="t") DestDeviceCode and DestBoxNumber are optional. If left out it will execute on the device it resides in and no network message will be create. If included it will create a DyNet message allowing for remotely updating button text.

Parameters
  • ButtonID is the index number of the button or text field. This is found on the button properties in the UI Creator. - Default of 1

  • TextMessage is the text string you would like displayed.

  • DestDeviceCode is the device code of the target device.

  • DestBoxNumber is the box number of the target device.

Requires UIC v3.1.8 or later. PDTS firmware v2.32 and earlier will terminate the task after executing a UIText() command.

Examples

Example 1

Will update button number 200 to say "New Text Here". No network message will be sent.

Task1()
{
UIText (ButtonId = 200, TextMessage = "New Text Here")
}

Example 2

Will send a command onto the network to change the text on button 11 of PDTS box number 30 to say "Garage is Open".

{
UIText(ButtonId=11,DestDeviceCode=0x79,DestBoxNumber=30,TextMessage="Garage is Open")
}