Change value of the one of data columns in the rendered document

Stimulsoft Reports.NET discussion
Post Reply
nozdUp
Posts: 5
Joined: Thu Apr 21, 2022 10:11 pm

Change value of the one of data columns in the rendered document

Post by nozdUp »

Dear Stimulsoft team

I have the rendered document in the *.mdc file. Berfore print I want change value of one data column in the document. How can I do this?

Code: Select all

var stiReport = new StiReport();
stiReport.LoadDocument(filePath); // path of the *.mdc file
// Which command for change one of the data columns?
Best regards,
nozdUp
Lech Kulikowski
Posts: 6266
Joined: Tue Mar 20, 2018 5:34 am

Re: Change value of the one of data columns in the rendered document

Post by Lech Kulikowski »

Hello,

You should change it in the report template - mrt file and then render the report again.

Or use the following code:
(report.RenderedPages.GetComponentByName("Text1") as StiText).Text = "new text";

Thank you.
nozdUp
Posts: 5
Joined: Thu Apr 21, 2022 10:11 pm

Re: Change value of the one of data columns in the rendered document

Post by nozdUp »

You helped me!

Thanks!
Lech Kulikowski
Posts: 6266
Joined: Tue Mar 20, 2018 5:34 am

Re: Change value of the one of data columns in the rendered document

Post by Lech Kulikowski »

Hello,

You are welcome.
Post Reply