ActiveReports 18 .NET Edition
Developers / Create Designer and Viewer Applications / Js Viewer Application / Update Security Token in Report Service
In This Topic
    Update Security Token in Report Service
    In This Topic

    The Js Viewer allows to specify a security token during creation. However, sometimes you may need to change a security token at run time. To do so, you should use the onRequest handler as demonstrated in the example below:

    Index.cshtml
    Copy Code
    const viewer = GrapeCity.ActiveReports.JSViewer.create({
      element: '#root',
      reportService: {
        onRequest: (init) => alert(init.credentials),
      },
    });