Live updates

GridControl

Show live prices in a grid that users can still sort while rows change.

Overview

The Blazor GridControl shows live data, such as prices changing several times a second, and users can sort it while the rows move. Use it for tickers, dashboards and order queues: change the bound rows in place and call StateHasChanged, and only the rows in view and the cells that changed re-render. A column Template draws color, arrows and SVG sparklines from each row's values.

Examples

#A portfolio that moves

Start the stream, sort by Change while it runs, or click Tick to step once; the status line reports rows changed and the server render time per tick.

Trend Name Type Price Change Change % Holdings Market value Unrealized P&L Updated
Razor Sharp GetawaysStock$48.20$0.000.00%400$19,280.00+$540.0018:40:25
Buttercup AirwaysStock$23.75$0.000.00%600$14,250.00+$1,284.0018:40:25
Plum & Underhill HotelsStock$112.40$0.000.00%150$16,860.00+$1,018.5018:40:25
Pennywhistle RailStock$64.10$0.000.00%250$16,025.00+$502.5018:40:25
Crumpet CruisesStock$38.90$0.000.00%300$11,670.00+$1,083.0018:40:25
Tiddlywink Travel TechStock$215.60$0.000.00%90$19,404.00($829.80)18:40:25
Marigold ResortsStock$87.30$0.000.00%200$17,460.00+$984.0018:40:25
Hobnob HostelsStock$12.85$0.000.00%900$11,565.00+$144.0018:40:25
Quickfoot JetsStock$156.20$0.000.00%120$18,744.00+$321.6018:40:25
Lamplighter LuggageStock$41.50$0.000.00%260$10,790.00($553.80)18:40:25
Fizzwick FerriesStock$27.40$0.000.00%500$13,700.00+$255.0018:40:25
Teacup CoinCrypto$61,450.00$0.000.00%4$245,800.00($13,804.20)18:40:25
Moonbeam TokenCrypto$2,740.00$0.000.00%25$68,500.00($1,783.75)18:40:25
Pumpernickel CoinCrypto$145.20$0.000.00%120$17,424.00($680.40)18:40:25
U.S. 10-Year Treasury NoteBond$99.85$0.000.00%1,000$99,850.00($1,470.00)18:40:25
Canada 30-Year Gov BondBond$96.40$0.000.00%600$57,840.00($5,658.00)18:40:25
France Gov Bond 2027Bond$102.15$0.000.00%500$51,075.00($1,950.00)18:40:25
Hedgerow Global Travel ETFETF$552.30$0.000.00%80$44,184.00($3,874.40)18:40:25
Larkspur Leisure IndexETF$478.60$0.000.00%90$43,074.00+$3,428.1018:40:25
Gooseberry Gold TrustETF$231.80$0.000.00%110$25,498.00+$2,063.6018:40:25
Thistlewood Muni Bond FundETF$108.40$0.000.00%300$32,520.00($1,188.00)18:40:25
21 rows

Paused. 21 instruments, no ticks yet.

Documentation

ParameterTypeDefaultDescription
Fieldstring—Property the column reads, and sorts by.
HeaderTextstring?—Header caption.
TemplateRenderFragment<object>?—Markup for the cell, given the row object as context; used here for the price tint, the change arrows, the trend line and the profit color.
TypeColumnType—Text, Number, Date or Boolean: decides editor, alignment default and sorting.
Formatstring?—Format string for the cell text when there is no template.
TextAlignTextAlign?nullLeft, Right or Center; the type's default when null.
Widthstring?—CSS width of the column.
AllowSortingbool—Off on the trend column, whose field only repeats the ticker.

The grid's own parameters on this page (AllowSorting, AllowSelection, AllowResizing, ShowRowCountInFooter, Height) are documented on Grid overview; the row window on 100k rows.

An unhandled error has occurred. Reload 🗙

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.