Search.../

unit

Sets or gets the unit of a slider's numeric input.

Description

A panel slider can only have one of the following unit values:

  • "NUMBER"
  • "PERCENTAGE"
  • "PIXELS"
  • "ANGLE"

Type:

stringRead & Write

Was this helpful?

Get an element's label

Copy Code
1let unit = $w("#myPanelSlider").unit; // "NUMBER"
Set an element's label

Copy Code
1$w("#myElement").unit = "PIXELS";