Created a datasource (MySQL database on my computer) and a dataset. Business as usual, nothing fancy. The dataset is actually a table consisting of two columns, one is the primary key, the second is the value.
On the Layout tab, I clicked the value column's value row, and just added this code to the onRender method (the Help says: "Script executed when the element is prepared for rendering in the Presentation engine"):
var val = this.getValue();
if (val == "boo") {
this.getStyle().backgroundColor = "#AAAAAA";
}
And voilá:
This BIRT thing is not bad, after all.
No comments:
Post a Comment