I have the following code which gets the formula of a chart. If I enter the function it should write the formula into the cell, however, if the chart is updated the result doesn't change until I go into the cell and press enter. How can I solve this?
Function ChartEq(CHRT As String) z = ActiveSheet.ChartObjects(CHRT).Chart.SeriesCollection(1).Trendlines(1).DataLabel.Text ChartEq = z End Function
Bookmarks