Selectable Table
Selection that survives searching and sorting: tick rows, select every loaded row, and act on the selection from a bar that appears when anything is ticked.
Best for: Bulk actions such as approve, assign or export.
Two parts to paste. The Screen YAML and the App.Formulas. The formulas are the same for all ten patterns, so an app with several of them needs that block once. Without it the screen has no colours, sizes or sample rows — or download the .msapp to skip the paste.
Preview and code
Wireframe — screenshots coming soon
Tick boxes
Per row, with a selected tint
Select all
Every loaded row, and a partial state
Bulk bar
Shows the count and the actions
Survives search and sort
Selection is keyed, not positional
How it works
The 2 techniques that make this pattern work on a list big enough to matter.
Selection keyed on the item key
colTseSelected holds item keys, so a selected row stays selected when the list is searched, filtered or re-sorted.
If(ThisItem.ItemKey in colTseSelected.ItemKey,
RemoveIf(colTseSelected, ItemKey = ThisItem.ItemKey),
Collect(colTseSelected, { ItemKey: ThisItem.ItemKey, Title: ThisItem.Title }))Select all means loaded
A gallery loads a page at a time. Select all ticks what is loaded, and says so, rather than claiming rows it has not fetched.
Connect to SharePoint
It ships on sample rows. The queries are already written the way SharePoint needs, so switching is a rename rather than a rewrite.
- Add your list as a data source.
- In
galTseRows.Items, replacecolTblItemswith your list (the src: Filter(colTblItems, ...) inside the With). - Delete
nfSeedTblItems();from the screen’s OnVisible. - If your columns are named differently, rename them in the screen, or add matching columns to the list.
- Index these columns:
Title,ItemKey,StatusKey,CategoryKey,Owner,Amount,DueDate.
Specific to this pattern
The bulk buttons are placeholders: wire each to a flow or a ForAll over colTseSelected.
The columns the patterns read
| Column | Type | Used for |
|---|---|---|
| Title | Text | The item's name; searched and sorted |
| ItemKey | Text | A unique reference, e.g. ITM-0042; searched, and the selection key |
| Owner | Text | Who the item belongs to |
| OwnerEmail | Text | The owner's email |
| StatusKey | Text | NotStarted, InProgress, OnHold or Completed |
| CategoryKey | Text | A key from nfTblCategories |
| PriorityKey | Text | High, Medium or Low |
| Amount | Number | A money value |
| DueDate | Date | When it is due; overdue rows turn red |
| Created | Date and time | Built in on a SharePoint list |
Rules that keep it working past 5,000 rows
- Every filter on a growing list must delegate: equality on an indexed column, StartsWith on text, and And or Or of those. in, Search() and <> do not delegate on SharePoint.
- An "All" choice must send no condition. Put the If outside the Filter and test the key with IsBlank, never with = "": a blank key compared with a column filters on blank and returns nothing.
- Sort with one literal SortByColumns per column. A column name held in a variable does not delegate.
- Index every column you filter or sort on before the list passes 5,000 items. Past that, SharePoint refuses an unindexed filter or sort outright.
- CountRows, Sum and Average do not delegate. Show rows loaded rather than a total, or keep totals in a list a scheduled flow maintains.
Get new components and templates when they drop
One email when something new ships. Unsubscribe anytime.
Community
Use the toolbar to format · or type markdown directly