|
|
Re: Documentation on Javascript [message #632594 is a reply to message #632554] |
Wed, 13 October 2010 14:22 |
|
Martijn,
These are good links. You should be able to do this with a script like:
if( row["ORDERNUMBER"] == 10101 ){
"Special Group";
}else{
"Normal Group " + row["ORDERNUMBER"];
}
In your case
if( row["transauthby"] == null ){
"Not Authorised";
}else{
"Authorised By " + row["transauthby"];
}
Jason
On 10/13/2010 8:18 AM, Martijn Cremer wrote:
> Chris wrote on Wed, 13 October 2010 03:21
>> Hi I'm new to BIRT and need some help.
>> I've got to the stage where I need to add some Javascript to make my
>> report work.
>> I have a group header where the text is "Authorised By
>> :"+dataSetRow["transauthby"]
>>
>> However dataSetRow["transauthby"]=null for the first group.
>> What I would like to set it too is "Not Authorised" when it is null.
>> How can I do this?
>> Is there a book that explains what classes and methods are available?
>> Also when should you use the field from available data sets and when
>> from data bindings.
>>
>> Thanks for your help.
>
>
> Im more of a Java person my self but you can start here:
>
> More about Mozilla Rhino (the Java Engine in BIRT)
> https://developer.mozilla.org/en/Rhino_documentation
>
> Then just normal JavaScript
> http://wiki.eclipse.org/Global_Functions_-_Useful_JavaScript _Functions_(BIRT)
>
>
> http://www.ecma-international.org/publications/files/ECMA-ST /ECMA-262.pdf
>
> Hope it helps
|
|
|
|
Powered by
FUDForum. Page generated in 0.03068 seconds