Set Text Of Crystal Report TextObject

M

Matt Theule

Visual Studio 2002, Crystal Reports.NET

I am unable to set the text of a text object in a crystal reports
report. I have found lots of examples for doing this, and what I have
does not throw any errors or warnings, but in my displayed report, the
textobject in question is not being changed.
Code:
crReport1 Rpt = new crReport1 ();
TextObject to =
(TextObject) Rpt.ReportDefinition.
Sections["ReportHeader"].ReportObjects["txtRHTitle"];
to.Text = "New Text";

Changing other aspects of the textobject work as expected:
to.Border.BackgroundColor = System.Drawing.Color.AliceBlue;
to.Border.HasDropShadow = true;
to.Border.TopLineStyle = CrystalDecisions.Shared.LineStyle.DoubleLine;

Only the text of the textobject does not change.

Any ideas? Thanks

MATT
Please reply to group, email is not valid.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top