_DC.InputGrid🔗 Dyalog Widget

produce a 2-column (or 2-row) grid of labels and inputs–

Constructor: [labels inputs | ;labels inputs]

labels – a vector of labels

inputs – a vector of input objects

N.B. – labels and inputs must be of equal length

Public Fields:

Border – 1 to draw borders around grid cells

Flip – 0 for labels on the left (vertical) or top (horizontal) 1 for labels on the right (vertical) or bottom (horizontal)

Horizontal – 0 for vertical layout (2-column) or 1 for horizontal layout (2-row)

Inputs – vector of inputs

Labels – vector of labels


label cells are assigned a class of (id,'_label')

input cells are assigned a class of (id,'_input')

This facilitates being able to easily assign styling to the cells


ipg←'myIpg' Add _.InputGrid ('lab1' 'lab2')(('inp1' New _.input)('inp2' New _.input))

Add _.Style '.myIpg_label' 'background-color:aliceblue' ⍝ set the label background color

Relevant Sample Pages:

Controls used on this page: Dyalog: Tabs Base HTML: style