I have some reports with drilldown, and I have now been asked to add a breadcrumbs style navigation t开发者_如何学运维o the report so the user can access the parent report again without having to use the litte 'back' button.
I was wondering if there was an easy way to do this? Currently I havent been able to find anything on the interwebs.
My solution right now is to pass the parameters for the parent report to its child then have a link back to the report using those parameters, however this really isnt the ideal solution.
Thanks
I have just implemented this using a standard hyperlink and a bit of javascript.
Add a textbox and set the text to something appropriate (e.g. "<< Back")
Set the action to "Go to URL" and set the URL to "javascript: history.go(-1)" (case sensitive).
I also formatted the text in blue and underlined to make it obvious it is a hyperlink
This code just uses javascript link to emulate clicking the Back button, so only goes back one level.
NOTE that this doesn't work in the Preview pane in SSRS, but does work in the browser (if you have javascript enabled).
If you have a number of levels and a rigid structure through which to drill down, you could implement a full breadcrumb trail by having multiple links and replacing -1 with -2 (to go back up 2 levels), -3 (to go back 3 levels) and so on.
You solution is pretty much what I have done. I don't think there is a way to make the parent "remember" the parameters.
I have added Parameter called "SpParentParam" and passed it to Child report. This parameter will have the parameters of the parent report. In my case, the parent report had multiple parameters which can be null and the child report did not know which specific parameters were used in the parent report
Similar to what peter has suggested but using "Go To Report" option in "Action" option (Right Click on "<> Action >> Go To Report).
After you add the report that you are supposed to go to, DO NOT FORGET to add the parameter that the report needs (one to which you are going to), this works in preview mode as well as after deploy.
Hope this helps.
Just in case anyone else is searching for this 6 years later, I tried Peter's method, which worked in IE, but apparently "broke" in Edge. Technically, it still worked, but the report needed to be rerun, prompting for the parameters again.
I had one detail report that was being called by several parent reports. I have the parent reports passing the report name and required run parameters (they all use the same set of parameters) to the child report.
Since the report parameters are specified per report when using the open report action, I had to set the parameters up as if I was hard-coding the report and then change the report field to the function that called my report name parameter.
Hope this helps someone else stuck on this issue post I.E.
精彩评论