Set up the report viewer in .NET 8.0, load a template, and connect the component to the application.

Embedding the viewer control. Drop a StiViewerControl onto the form, then load and render a report and assign it to the control:
var report = new StiReport();
report.Load(@"Reports\SimpleList.mrt");
report.Render();
stiViewerControl1.Report = report;

Opening the report in a window. If you do not need an embedded control, call Show() on the report and it opens in a ready-made preview window:
var report = new StiReport();
report.Load(@"Reports\SimpleList.mrt");
report.Show();

The difference is control over the layout: the StiViewerControl lets you place the preview anywhere in your own interface, while Show() is the quickest way to display a report without designing a form.

Используя этот сайт, вы соглашаетесь на использование файлов Cookie для аналитики и персонализированного контента. Файлы Cookie хранят полезную информацию на вашем компьютере, чтобы помочь нам повысить эффективность и удобство использования. Для получения дополнительной информации, пожалуйста, прочтите Конфиденциальность и Использование Cookie.