This sample project demonstrates how to add the HTML5 viewer on the ASPX page and display a simple report. To add the viewer, it is enough to add the StiWebViewer component from the Stimulsoft.Report.Web library:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="Show_Report_in_the_Viewer.Default" %>
<%@ Register assembly="Stimulsoft.Report.Web" namespace="Stimulsoft.Report.Web" tagprefix="cc1" %>

<!DOCTYPE html>
<head runat="server">
	<title>Show report in the Viewer</title>
	<form id="form1" runat="server">
		<cc1:StiWebViewer ID="StiWebViewer1" runat="server"
			OnGetReport="StiWebViewer1_GetReport" />

To display the report, you should add the OnGetReport event, in which you need to load the report and, if required, to register the data:
protected void StiWebViewer1_GetReport(object sender, Stimulsoft.Report.Web.StiReportDataEventArgs e)
	var report = new StiReport();

	e.Report = report;

In the screenshot below you can see the result of the sample code:

Showing a Report in the Viewer

By using this website, you agree to the use of cookies for analytics and personalized content. Cookies store useful information on your computer to help us improve efficiency and usability. For more information, please read the privacy policy and cookie policy.