Skip to Content
Former Member
Jul 06, 2010 at 08:23 AM

CR2008 - Set chart titles during run time


Hello community!

Is there a way to change the chart titles during runtime with the fullversion?

I have the following code to change the text of the "FieldHeadingObject" and "TextObject" and this is working.

foreach (CrystalDecisions.CrystalReports.Engine.ReportObject repObject in sec.ReportObjects)
   if (repObject.Kind == ReportObjectKind.TextObject ||
       repObject.Kind == ReportObjectKind.FieldHeadingObject)
        ((CrystalDecisions.CrystalReports.Engine.TextObject)repObject).Text = "my new Text";

How can I change the titles of the chart object?

I know already that there is the class "ChartTextOptionsClass"

Does someone know how I could access the TextOptions in the ChartObject so that the new Titles are displayed in the report?

Thank you