BCGSuite for MFC
void CBCGPChartLegendVisualObject::InvalidateLegendContent ( BOOL  bRedraw)

Invalidates legend content

Usually this method is called automatically when you connect or disconnect related charts using AddRelatedChart() and RemoveRelatedChart(). It forces a legend to rebuild its content next time it's going to paint itself or calculate size.

You might need to call this method explicitly if you dynamically add or remove series or data points (if these data points were added to legend) to/from related charts.

Parameters
bRedrawspecifies whether a legend should be redrawn