Refresh my chart

Hi everyone
I am trying to refresh the extension function of my chart I read this solution but I do not know where it put the script if in the chart configuration or in the root container, I would be very grateful if someone has already had this problem and how do I solve it or if is there another way to refresh the chart
I would greatly appreciate any contribution

You put the trigger operations in a propertyChange event or wherever else you have the change happening (or button press or whatever) that is the reason you want the chart to update. That's up to you. The trick is to change something on the Classic Chart that fires its internal "start over" event--just updating the plot data isn't enough. As noted in this thread, simply assigning the same value to the plot background is enough:

However, beware of the memory leak. Fixed in v8.0.6, but not yet fixed in v7.9.x.

Thank you very much engineer Phil
it worked what i recommend i put in a propetychange a script using .plotBackground and it worked thanks for your suggestion