In SQL Server Reporting Services, Actions are used to add additional functionality to Reports. It means, we can define the events to take place when users click on text box or certain area displayed on a report.
TIP: Actions can be defined on Matrix, Table (Together Tablix), Charts, Data bars, Pie Charts, gauges and so on
From the above screenshot you can observe that, There are three types of actions:
- Go to report: Most commonly called as Drill Through Action. This type of action allows the user to navigate from one report to another by clicking an object in main report.
- Go to bookmark: This type of action allows the user to navigate to a pre-defined bookmark within the same SSRS report. For instance, If the report is too long then we can define the bookmarks to navigate easily.
- Go to URL: This type of action allows the user to navigate from SSRS report to specified URL. For instance, if we are displaying sales by country and user want to view the Heat Map of each country when he clicked on it then we can use this Go to URL action
SSRS Actions Go To URL Example
Let us see the Report preview as well. If you observe the below screenshot, It’s just a normal Table Report displaying tutorialgateway.org posts archive.
Here we are going to apply go to url action on Tutorials column so, Right click on the Tutorials text box and select the Text Box Properties.. option from the context menu as shown below
Once you select the Text Box Properties.. option, a new window will be opened to configure the properties. Please Navigate to Action tab and choose Go to URL option as shown below.
If you know the URL then you can Hard code it in the text box otherwise, Please select the fx button like we did
With in the Expression window, Please write the following expression
="http://www.tutorialgateway.org/" + LCase(Fields!Tutorials.Value.ToString())
We are just adding the user clicked text to www.tutorialgateway.org/ URL. For instance, if user click on MDX then mdx is added after the /
Click Ok to close the Expression window
Next, Please navigate to Font tab and change the color of the Text. This will help the end-user to identify as Hyperlink
Click Ok to finish enabling Go to URL action on table report.
Let us see the report preview by clicking preview tab
Once we click on SQL, our default browser will open the www.tutorialgateway.org/sql/ as shown below
Thank You for Visiting Our Blog