how can i inser script code in BIRT

I am using BIRT in our project. That has a requirement is dynamic display three different kind of graph and switch between different graph. It is my first time to use BIRT. So I don’t know how to control the chart in our report of BIRT. I found a document of BIRT introduced how to insert script code in the report scope. The detailed description following:
The First: I defined a table element that has two rows and columns.

The Second: in the first row and first column. I insert the text element and choice the element type is HTML, so you can edit html element, such as I insert three “input” element of html, its type is radio. When I click one of three radio elements, a kind of graph will be shown and the others will be hidden. So you must defined row and column “bookmark” property. You can use the bookmark in your script, like this “document.getElementById(“bookmark”)”,obtain the element object.

Third: edit your script code, like following:

function DisplayCustomer(id0,id1,id2) {

document.getElementById("chart"+id0).style.display="block"
document.getElementById("chart"+id1).style.display="none"
document.getElementById("chart"+id2).style.display="none"

}
Fourth: through the above code display or hidden the different graph.

你可能感兴趣的:(html,jquery)