# Action

Defines a hyperlink.

### Description

The Action structure defines a hyperlink. There are five major kinds of actions:

- Hyperlink: To an external web site, e-mail system, etc.
- Bookmark Link: To a location within this report as specified by a bookmark.
- Drill-though: To a location within another report as specified by a bookmark.

The drill-though link can link to an existing report, or request to run a new report. It can optionally include:

- Parameters to pass when creating a new report.
- A location within the target report as specified by a search.
- A location within the target report as specified by a bookmark.

The Hyperlink property returns a standard web-style link with "http:" or "mailto:" prefix. Expression hyperlinks can include special BIRT features (search and so on), but only as encoded into a URL. If the link wants to jump to a specific target within the document, encode that target within the URL as defined by target document type. (For example: http://foo.com/docs/myDoc.html#myTarget.)

If the user provides a relative URL, it is assumed to be relative to the same web server that is being used to view the report. The exact semantics are implementation-specific in the open source release. In the commercial release, the URL is relative to the web server that hosts ActivePortal.

A bookmark link simply identifies a bookmark identified within this report. Use the Bookmark property of a report item to create the target bookmark.

#### Property Usage

Property | Link Type
--- | ---
| Hyperlink | Bookmark Link | Drill-through
`targetWindow` | X |  | X
`hyperlink` | X |  |
`bookmarkLink` |  | X |
`drillThroughBookmarkLink` |  |  | X
`reportName` |  |  | X
`drillThroughParamBindings` |  |  | X
`drillThroughSearch` |  |  | X

### See Also

## formatType

Format of the target link.

### Description

Format of the target link, can be pdf or html link.

## linkType

The kind of link: hyperlink, bookmark link or drill-though.

### Choices

- none: No link is defined.
- hyperlink: A link to a web page, "mailto:", or other web resource.
- drill-through: A link to another report.

### Description

This property identifies the kind of link. The link type determines which link properties to use as shown above. The default is a hyperlink.

A drill-through is a link to another report. The report name is given as a relative or absolute name. If the name is relative, then the target document is on the same web (application) server as the current report. For example:

- report1: in the same virtual directory as this report.
- ../report2: Up one virtual directory from this report.
- ../summary/report3: In a sibling directory to this report.
- /reports/summary/report4: In an absolute location on this web server.

The destination can be any type of report as supported by the web server interface that receives the link commands. If the destination is a BIRT design, the report will be run.

### See Also

## targetWindow

The name of the target browser window for the link.

### Description

The name of the target browser window for the link. Used only for the Hyperlink and Drill-Through options, ignored for the Bookmark Link option. This property is optional.

### See Also

## uri

Expression that provides the web URL.

### Description

The expression that provides the actual link. This is a Web-style hyperlink and includes http:, mailto: and other URLs. Both relative and absolute URLs are allowed. The meaning of relative URL depends on the deployment environment.

If the property is not set, then no link is defined, even if the link type is set to "Hyperlink."

### See Also

## targetBookmark

Target bookmark defined within this same report, or another report for a drill-though link.

### Description

The target bookmark within this report.

If the link type is bookmark link then the value here must match a bookmark defined within the report. If the bookmark target is not defined, then the link will do nothing.

If link type is drill-though link then the value here must match a bookmark defined within the target report. If the bookmark target is not defined, then the drill-though link will display the first page of the report.

### See Also

Report Item `bookmark` Property

## reportName

Name of the target report for a drill-through link.

### Description

The name of a document on the same server as this report. Can include relative or absolute names. If the suffix is omitted, it is assumed to be 1) a BIRT document or 2) a BIRT design. If the report name is blank, then the no hyperlink is defined even if the link type is set to Drill-though.

### See Also

## paramBindings

Optional list of parameter bindings for the target. Used when the hyperlink is used to run a report.

### Description

Optional list of parameter bindings for the target. Used when the hyperlink is used to run a report. The bindings evaluate an expression within the current report, and bind that value to a report parameter in the target report. For example, if the current report is a list of customers, the report can include a hyperlink that runs a report that shows any open orders for that customer. In this case, the parameter bindings pass the customer ID to the target report.

### See Also

## search

An optional set of search criteria for the target report for a drill-though link.

### Description

Optional list of search criteria. The report is run (if needed) or an existing report is opened. Then, BIRT performs a search on the target report based on the search criteria entered here.

For example, if the current report is a list of customers, the report can include a hyperlink that links to a report that shows open orders for all customer, then search for the customer’s orders. In this case, the search criteria look for the customer’s ID within the target report.

### See Also