The dashboard viewer exposes its events as component bindings — here the export event fires when the user exports the dashboard.

In React.
import { Viewer, Stimulsoft } from "stimulsoft-dashboards-js-react/viewer";

function App() {
    var report = new Stimulsoft.Report.StiReport();
    report.loadFile("Dashboards/Dashboard.mrt");

    var options = new Stimulsoft.Viewer.StiViewerOptions();
    options.toolbar.showSendEmailButton = true;

    function onBeginExportReport(args: Stimulsoft.Viewer.BeginExportReportArgs) {
        alert("onBeginExportReport");
    }

    return <Viewer options={options} report={report} onBeginExportReport={onBeginExportReport} />;
}

How it works. Each event is a component output, so your app reacts to what the user does 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.