Page 1 of 1

what ajax function to call for reloading the report viewer?

Posted: Fri Jun 07, 2013 7:47 pm
by bobsov
I have a unique requirement where I need to do auto-refresh for the mobile version of report viewer page. As I have other items in the page itself, I don't want to page reload but rather call ajax functionality to reload the viewer at a set interval. what function should I be calling to make this happen in javascript?

Re: what ajax function to call for reloading the report view

Posted: Mon Jun 10, 2013 8:14 am
by Vladimir
Hello,

Please specify which component you are using: MobileViewer or MvcMobileViewer?

Thank you.

Re: what ajax function to call for reloading the report view

Posted: Mon Jun 10, 2013 1:34 pm
by bobsov
Mobile viewer

Re: what ajax function to call for reloading the report view

Posted: Tue Jun 11, 2013 7:59 am
by Vladimir
Hello,

Unfortunately, at the moment there is no specific method for Mobile Viewer, we will try to prepare a solution for you. We need some time.

Thank you.

Re: what ajax function to call for reloading the report view

Posted: Tue Jun 11, 2013 2:07 pm
by bobsov
Thanks Vladimir. I will wait for this solution.

Re: what ajax function to call for reloading the report view

Posted: Wed Jun 12, 2013 10:47 am
by HighAley
Hello.

Let us know if you will need any additional help.

Thank you.

Re: what ajax function to call for reloading the report view

Posted: Sun Jun 23, 2013 1:58 pm
by bobsov
I was able to call ajax refresh every 10 seconds doing some digging in codes.

Here is the code on my main page that did the trick.

Code: Select all

var autorun = self.setInterval(function() {
		var button = document.getElementById("StiMobileViewer1_Submit");
		button.action();
	}, 10000);
May be there is a better a solution but this works great.

Re: what ajax function to call for reloading the report view

Posted: Mon Jun 24, 2013 5:37 am
by bobsov
Also with slight modification in source code( StiMobileViewer.cs), I was able to make this work for reports that do not have parameters.

Cheers!!!

Re: what ajax function to call for reloading the report view

Posted: Mon Jun 24, 2013 8:04 am
by HighAley
Hello.

We are very great to work with such customers.

Thank you for using our product.

Re: what ajax function to call for reloading the report view

Posted: Tue Jun 25, 2013 7:12 am
by Vladimir
Hello,

Alternatively, you can use the following code:

Code: Select all

setTimeout("jsStiMobileViewer1.sendToServer('NavigationReport')", 10000);
StiMobileViewer1 - Mobile Viewer ID.


Thank you.