Andrew
Andrew

Reputation: 11

Pine script for refreshing chart on TradingView

I was wondering if there is a possibility to make a script that refreshes the chart after 5 min.

Because if you refresh your script it solves the repainting issue.

Love to hear if somebody can help me with this.

Upvotes: 1

Views: 1334

Answers (1)

vitruvius
vitruvius

Reputation: 21332

No, it is not possible to do that and ideally you should avoid repainting.

Events that trigger the execution of a script:

  • A new symbol or resolution is loaded on a chart.
  • A script is saved or added to the chart from the Pine Editor.
  • A value is modified in the script’s Settings/Inputs dialog box.
  • A value is modified in a strategy’s Settings/Properties dialog box.
  • A browser refresh event is detected.

Refreshing the page is not a solution to the repainting. There are several methods to avoid it.

Upvotes: 0

Related Questions