{"title":"SourceTableView property on pages","url":"https://jonas-paprotka.de/docs/dev-itpro/developer/properties/devenv-sourcetableview-pages-property/","by":"JOP-AL","license":"Copyright (c) Microsoft Corporation. CC BY 4.0, https://creativecommons.org/licenses/by/4.0/; code samples MIT. From https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/properties/devenv-sourcetableview-pages-property, MicrosoftDocs/dynamics365smb-devitpro-pb at 828b6ee (2026-11-19). Changed: includes filled in, links to this site, and for agents shortened without dropping a fact.","credit":"Microsoft Corporation, CC BY 4.0","origin":"https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/properties/devenv-sourcetableview-pages-property","source":{"name":"Business Central developer and IT pro docs","repo":"https://github.com/MicrosoftDocs/dynamics365smb-devitpro-pb","commit":"828b6ee72fcd75755627cd6011f3d20899217ab2","date":"2026-11-19"},"checked":"2026-11-19","description":"Learn how the SourceTableView property sets the key, sort order, and filters for records on a page in Dynamics 365 Business Central.","date":"2026-10-01","meta":{"topic":"reference"},"outline":[{"level":2,"title":"Applies to","slug":"applies-to","at":144,"chars":21},{"level":2,"title":"Example","slug":"example","at":165,"chars":1200},{"level":2,"title":"Remarks","slug":"remarks","at":1365,"chars":320},{"level":2,"title":"Related information","slug":"related-information","at":1685,"chars":103}],"text":"> Version: _Available from runtime version 1.0._\nSpecifies the key, sort order, and filters that define the view of the source table on a page.\n## Applies to\n Pages\n## Example\n```al\npage 50101 MyCustomers\n{\n    PageType = List;\n    SourceTable = Customer;\n    SourceTableView = sorting(Name) order(descending)\n        where(\"Balance (LCY)\" = filter(>= 50000), \"Sales (LCY)\" = filter(<> 0));\n\n    layout\n    {\n        area(Content)\n        {\n            repeater(Customers)\n            {\n                field(Name; Rec.Name)\n                {\n                    Caption = 'Name';\n                    ToolTip = 'Specifies the customer name.';\n                    ApplicationArea = All;\n                }\n                field(Address; Rec.Address)\n                {\n                    Caption = 'Address';\n                    ToolTip = 'Specifies the customer address.';\n                    ApplicationArea = All;\n                }\n                field(Balance; Rec.\"Balance (LCY)\")\n                {\n                    Caption = 'Balance (LCY)';\n                    ToolTip = 'Specifies the customer balance in local currency.';\n                    ApplicationArea = All;\n                }\n            }\n        }\n    }\n}\n```\nFor information about finding and limiting records in a list, see Sorting, searching, and filtering lists</ui-enter-criteria-filters>.\n## Remarks\nIf 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.\n## Related information\n../devenv-page-object\ndevenv-sourcetableview-xmlports-property\ndevenv-properties"}