Sidechair

table.all

Browse the reference

Holds every table the script has made, so a loop can reach tables whose variables are out of scope.

Try it in the editor

Loop over it to restyle, move or delete all tables at once, including ones whose variables are no longer reachable. Every item is a table.

The array is managed by Pine. Remove a table from the chart with table.delete(), not by editing the array.

Type

array<table>

Example

Pine ScriptDim every table in one passOpen in editor
//@version=6
indicator("table.all: restyle all", overlay = true)
var t = table.new(position.top_right, 1, 1)
if barstate.islast
    table.cell(t, 0, 0, "Panel")
    for tb in table.all
        table.set_bgcolor(tb, color.new(color.black, 80))
        table.set_border_width(tb, 1)
plot(close)

See also

Runs on Sidechair