Skip to content

ButtonTable

Button Table is a container that can display one or more buttons on a section page. You can include Button Item controls in a Button Table to fire actions when pressed.

ButtonTable Properties

Property Type Required
Buttons ButtonItem No
DataSubscriptions DataSubscriptions No
EmptySection EmptySection No
Footer Footer No
Header Header No
Layout Button Layout No
Separators Separators No
Visible boolean No
_Name string No
_Type const Yes

Buttons

  • type: ButtonItem[]
  • at least 1 items in the array

All array items must be of the type: ButtonItem


DataSubscriptions

Array of data change events to subscribe to.


EmptySection

A section that will be displayed when the list is empty, this only applies if you are using Target binding. Allows you to show custom label when the list is empty.


Footer bar to be displayed below this control's content section.


Header bar to be displayed above this control's content section.


Layout

The layout of buttons.


Separators

To provide more flexibility with rendering of controls and sections, set the visibility of the separator lines.


Visible

Set the visibility of this control.

  • type: boolean

_Name

  • type: string

_Type

  • type: const

The value of this property must be:

"Section.Type.ButtonTable"

Examples

{
  "_Type": "Page",
  "_Name": "ButtonSectionPage",
  "Caption": "Button section Page",
  "Controls": [
    {
      "Sections": [
        {
          "_Type": "Section.Type.ButtonTable",
          "Buttons": [
            {
              "Title": "Button1",
              "OnPress": "/MDKApp/Actions/Messages/Message1.action",
              "TextAlignment": "left"
            } 
            {
              "Title": "Button2",
              "OnPress": "/MDKApp/Actions/Messages/Message2.action",
              "TextAlignment": "center"
            }
          ]
        }
      ]
    }
  ]
}

{
  "_Type": "Page",
  "_Name": "ButtonSectionStyle",
  "Caption": "Button Section Styles",
  "Controls": [
    {
      "_Type": "Control.Type.SectionedTable",
      "_Name": "SectionedTable",
      "Sections": [
        {
          "_Type": "Section.Type.ButtonTable",
          "Buttons": [
            {
              "Title": "Seek and ...",
              "Visible": true
            },
            {
              "Title": "Hidden button",
              "Visible": false
            }
          ]
        },
        {
          "_Type": "Section.Type.ButtonTable",
          "Buttons": [
            {
              "Title": "Destroy",
              "Style": "DestructiveActionButton"
            }
          ]
        }
      ]
    }
  ]
}