SourceTableView property on pages

Version: Available from runtime version 1.0.

Specifies the key, sort order, and filters that define the view of the source table on a page.

Applies to

  • Pages

Example

page 50101 MyCustomers
{
    PageType = List;
    SourceTable = Customer;
    SourceTableView = sorting(Name) order(descending)
        where("Balance (LCY)" = filter(>= 50000), "Sales (LCY)" = filter(<> 0));

    layout
    {
        area(Content)
        {
            repeater(Customers)
            {
                field(Name; Rec.Name)
                {
                    Caption = 'Name';
                    ToolTip = 'Specifies the customer name.';
                    ApplicationArea = All;
                }
                field(Address; Rec.Address)
                {
                    Caption = 'Address';
                    ToolTip = 'Specifies the customer address.';
                    ApplicationArea = All;
                }
                field(Balance; Rec."Balance (LCY)")
                {
                    Caption = 'Balance (LCY)';
                    ToolTip = 'Specifies the customer balance in local currency.';
                    ApplicationArea = All;
                }
            }
        }
    }
}

For information about finding and limiting records in a list, see Sorting, searching, and filtering lists.

Remarks

If you combine a descending SourceTableView sort order with an overridden OnFindRecord trigger, the page might display the last record instead of the first when it opens. To control the initial record, use Rec.FindFirst() in the OnOpenPage trigger or implement the required search behavior in OnFindRecord.

Page object
SourceTableView property for XMLports
Properties