Hyperlinks in HTML5 Charts


This section describes functionality that can be restricted by the software license for Jaspersoft Studio. If you don’t see some of the options described in this section, your license may prohibit you from using them. To find out what you're licensed to use, or to upgrade your license, contact Jaspersoft.

For most types of elements, hyperlinks are created as described in Anchors, Bookmarks, and Hyperlinks. For HTML5 charts, they are defined in a different way.

While the creation of hyperlinks for text fields, images and other object, like for instance the items of JfreeChart based charts involve the use of the hyperlink panel seen in the previous chapter, working with hyperlink with the HTML5 Component involve a little more work. This is because the HTML5 charts are based on a multi-dimensional dataset the values that are attached to a dimension so that the URL of the link is formed by values that differ in nature.

The final hyperlinks displayed in an HTML5 chart are created by a specific extension to the HTML5 chart component, which evaluates properties attached to a measure (what the user actually clicks in a chart are items like a point, a line, a bar, a slice, which represent a measure).

To understand how to configure a hyperlink in HTML5 charts, let's start with a basic sample. We create a simple bar chart and set the hyperlink of each column to the same URL (http://www.jaspersoft.com).