Example #1
0
        protected void StiWebViewer1_GetReport(object sender, Stimulsoft.Report.Web.StiReportDataEventArgs e)
        {
            var report = new StiReport();

            report.Load(Server.MapPath("Reports/TwoSimpleLists.mrt"));

            e.Report = report;
        }
        protected void StiWebDesigner1_GetReport(object sender, Stimulsoft.Report.Web.StiReportDataEventArgs e)
        {
            var dashboardPath = Server.MapPath("Dashboards/DashboardChristmas.mrt");
            var report        = StiReport.CreateNewDashboard();

            report.Load(dashboardPath);

            e.Report = report;
        }
Example #3
0
        protected void StiWebViewer1_GetReport(object sender, Stimulsoft.Report.Web.StiReportDataEventArgs e)
        {
            string dashboardPath = Server.MapPath("Dashboards/DashboardChristmas.mrt");
            var    report        = new StiReport();

            report.Load(dashboardPath);

            e.Report = report;
        }
        protected void StiWebViewer1_GetReport(object sender, Stimulsoft.Report.Web.StiReportDataEventArgs e)
        {
            var name          = Page.Request.QueryString["name"] ?? "DashboardChristmas";
            var dashboardPath = Server.MapPath($"Dashboards/{name}.mrt");
            var report        = StiReport.CreateNewDashboard();

            report.Load(dashboardPath);

            e.Report = report;
        }
Example #5
0
        protected void StiWebDesigner1_GetReport(object sender, Stimulsoft.Report.Web.StiReportDataEventArgs e)
        {
            var fileName = Page.Request.QueryString.Get("id") ?? "DashboardChristmas";

            var report = new StiReport();

            report.Load(Server.MapPath($"~/Dashboards/{fileName}.mrt"));

            e.Report = report;
        }
Example #6
0
        protected void StiWebViewer1_GetReport(object sender, Stimulsoft.Report.Web.StiReportDataEventArgs e)
        {
            string reportPath = Server.MapPath("Reports/SimpleList.mrt");

            e.Report = new StiReport();
            e.Report.Load(reportPath);

            string  dataPath = Server.MapPath("Data/Demo.xml");
            DataSet data     = new DataSet();

            data.ReadXml(dataPath);
            e.Report.RegData(data);
        }
        protected void StiWebViewer1_GetReport(object sender, Stimulsoft.Report.Web.StiReportDataEventArgs e)
        {
            // Create new report
            var report = new StiReport();

            // Load report template
            report.Load(Server.MapPath("Dashboards/Dashboard.mrt"));

            // Load a JSON file
            var jsonBytes = File.ReadAllBytes(Server.MapPath("Dashboards/Demo.json"));

            // Get DataSet from JSON file
            var json    = StiJsonConnector.Get();
            var dataSet = json.GetDataSet(new StiJsonOptions(jsonBytes));

            // Remove all connections from the report template
            report.Dictionary.Databases.Clear();

            // Register DataSet object
            report.RegData("Demo", "Demo", dataSet);

            // Show Report in the Web Viewer
            e.Report = report;
        }
Example #8
0
        protected void StiWebViewer1_DesignReport(object sender, Stimulsoft.Report.Web.StiReportDataEventArgs e)
        {
            var fileName = Page.Request.QueryString.Get("id") ?? "DashboardChristmas";

            Response.Redirect("/Designer.aspx?id=" + fileName);
        }