I am looking into replacing the ReportViewer toolbar. Just doing discovery right now. I know about the JavaScript api for the report viewer. This does not include an API for the pagination controls.
I have dug around in the generated HTML and have figured out how to trigger a postback to do the pagination. Calling the following in Javascript works even with the toolbar not being displayed.
__doPostBack("ReportViewer1$ctl05$ctl00$Next$ctl00")
I don’t know the gotchas of calling a post back like this. As the string being passed into the method is the name of the input button. It seems like the name may be able to change. I also don’t know what the $ctl stuff means.
I am aware of how to get reportviewer to not page reports by setting the interactive height to zero. I am just exploring all my options at this time.
Is there an easier way to do pagination without the ReportViewer toolbar being displayed? If not, what are the gotchas of triggering a postback?
The final solution to this was to do a postback with customer arguments.
Client Side JS:
The two fields that get populated are what is created by default for ASP.NET postbacks.
Server Side C# in the ASP.NET pages OnLoad event: