Hi,
There is a RichTextBox and 2 TextBox in my report. I want to change their values at runtime and Show Report.How can i achieve this ?
Access Report in Runtime
Access Report in Runtime
Hello,
You can use the following code:
Thank you.
You can use the following code:
Code: Select all
StiReport report = new StiReport();
report.Load("e:\\report.mrt");
StiText txt = report.GetComponents()["Text1"] as StiText;
txt.Text = "Sample Text";
StiRichText rt = report.GetComponents()["RichText1"] as StiRichText;
RichTextBox rtb = new RichTextBox();
rtb.LoadFile("e:\\1.rtf");
rt.RtfText = rtb.Rtf;
report.Render();
report.Show();