showing the next dashboard in a report with code
-
- Posts: 11
- Joined: Tue May 26, 2020 1:56 pm
showing the next dashboard in a report with code
Hi
I have a report that has 2 dashboard-pages in it.
I would like to alternate between those two in a viewercontrol by using a timer.
How could I do this in c#?
I have a report that has 2 dashboard-pages in it.
I would like to alternate between those two in a viewercontrol by using a timer.
How could I do this in c#?
-
- Posts: 6366
- Joined: Tue Mar 20, 2018 5:34 am
Re: showing the next dashboard in a report with code
Hello,
Please check the following code:
//where jsStiWebViewer1 - "js" + Viewer ID
jsStiWebViewer1.onready = function () {
var pageNumber = 0;
setInterval(function () {
pageNumber = pageNumber == 0 ? 1 : 0;
jsStiWebViewer1.reportParams.pageNumber = pageNumber;
jsStiWebViewer1.controls.dashboardsPanel.buttons[pageNumber].select();
jsStiWebViewer1.postAction("Refresh");
}, 10000);
}
Thank you.
Please check the following code:
//where jsStiWebViewer1 - "js" + Viewer ID
jsStiWebViewer1.onready = function () {
var pageNumber = 0;
setInterval(function () {
pageNumber = pageNumber == 0 ? 1 : 0;
jsStiWebViewer1.reportParams.pageNumber = pageNumber;
jsStiWebViewer1.controls.dashboardsPanel.buttons[pageNumber].select();
jsStiWebViewer1.postAction("Refresh");
}, 10000);
}
Thank you.
-
- Posts: 11
- Joined: Tue May 26, 2020 1:56 pm
Re: showing the next dashboard in a report with code
stiDashboardViewerControl1.reportParams
and
stiDashboardViewerControl1.controls.dashboardsPanel.button
don't seem to exist. Any other way I can do this?
and
stiDashboardViewerControl1.controls.dashboardsPanel.button
don't seem to exist. Any other way I can do this?
-
- Posts: 6366
- Joined: Tue Mar 20, 2018 5:34 am
Re: showing the next dashboard in a report with code
Hello,
We need some additional time to investigate the issue, we will let you know about the result.
Thank you.
We need some additional time to investigate the issue, we will let you know about the result.
Thank you.
Re: showing the next dashboard in a report with code
Hello,
Please, check the name of the Viewer.
It seems that you should replace it with the right ID.
Thank you.
Please, check the name of the Viewer.
It seems that you should replace it with the right ID.
Thank you.
-
- Posts: 11
- Joined: Tue May 26, 2020 1:56 pm
Re: showing the next dashboard in a report with code
I'm sorry, but I'm not using the javascript-viewer.
I'm using the dashboard viewer in a winforms application.
Or am I missing something?
I'm using the dashboard viewer in a winforms application.
Or am I missing something?
-
- Posts: 6366
- Joined: Tue Mar 20, 2018 5:34 am
Re: showing the next dashboard in a report with code
Hello,
Unfortunately, at the current moment, it is not possible in winforms.
Thank you.
Unfortunately, at the current moment, it is not possible in winforms.
Thank you.
-
- Posts: 6366
- Joined: Tue Mar 20, 2018 5:34 am
Re: showing the next dashboard in a report with code
Hello,
As a way, you can split pages in dashboards into separate templates and by timer load necessary dashboard and refresh the viewer.
Thank yuo.
As a way, you can split pages in dashboards into separate templates and by timer load necessary dashboard and refresh the viewer.
Thank yuo.