Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

@Layout

Describes the layout of a screen or report: Label, Input, Column, DataGridView, Block, or any other Name(...) as a generic control. Control names may carry @ optionally (@Label/Label are equivalent).

Controls with their own grammar

ControlSyntaxValid inDescription
LabelLabel(x, y, text)Program, ScreenStatic label at x,y. text can be &Variable, "literal" or a bare field name. x,y = 1,1 (exact corner) is forbidden — DDS rejects any field there.
BlockBlock("Name")[ Label(...), ... ]ProgramA named, printable group of Labels — an instance is printed with Print("Name") from @Source.
InputInput("Name", x, y, text, &Variable[, enabled])ScreenEditable field at x,y. "Name" identifies the control (read with CurrentInput()). &Variable is where the entered value is stored. enabled optional (default true): a literal, &Variable or a function returning number (non-zero = enabled), re-evaluated before every redraw. x,y = 1,1 is also forbidden.
ColumnColumn(text, variableOrField[, Input|Hidden])inside DataGridView onlyThe optional 3rd argument makes the column editable (Input) or invisible (Hidden).
DataGridViewDataGridView("Name", x, y, rows[, separator])[ Column(...), ... ]ScreenA named grid at x,y showing rows visible rows. The name is required and unique among Input/DataGridView controls. See DataGridView for the full guide.

Example (Screen)

@Layout {
    @Label(1,2,&Program)
    @Label(1,70,&MyDate)
    @Input("txtRequestNo",3,1,"Request No.: ",&RequestNo,true)
    @DataGridView("GridRequests",6,1,8," ") [
        @Column("Country",&nCountry)
        @Column("User",&cUser)
    ]
}

Example (Program, with a printable Block)

@Layout {
    @Block("Header") [
        Label(1,1,"Sales Report")
        Label(2,1,&Today)
    ]
}
@Source {
    Print("Header")
}

@Layout is optional in Program (a purely batch program, with no printed output, doesn’t need it) but required in Screen. Doesn’t apply to tables.