Page 1 of 1

Reading content of StiText after finished rendering

Posted: Wed Nov 16, 2016 7:20 pm
by Prandl33
Hello,
I want to read the content of a StiText component from the rendered report.
Here are my codesnippets of my experiments.

Report.RenderWithWpf(false);

foreach (StiPage page in Report.RenderedPages.Items) {
StiText metaText05 = (StiText) page.GetComponents()["Text05"];
StiText metaText06 = (StiText) page.GetComponents()["Text06"];
}

The metaText05.Text.Value and metaText06.Text.Value always are empty.
How do I have to write it so it works properly.

Thank you
Prandl

Re: Reading content of StiText after finished rendering

Posted: Thu Nov 17, 2016 6:12 am
by Prandl33
Hello,
I have the solution:

string text = (page.Report.GetComponents()["Text05"] as StiText).Text.Value

Thank you
Prandl

Re: Reading content of StiText after finished rendering

Posted: Fri Nov 18, 2016 5:14 am
by Andrew
Dear Prandl,

Thank you for sharing your solution and letting us know about this.

Thank you.