Hi all,
I want to access text component's data set in the script function, as: onCreate, or onPrepare, or onRender.
I tried these three functions, and all get error messages.
So I do not know how to do this job.
Would you like to give suggestions?
Thanks in advance for your help!
The error message is bellowing:
The following items have errors:
Text (id = 382):
+ There are errors evaluating script "importPackage(Packages.java.util);
localizationTextManager = reportContext.getAppContext().get("localizationTextManager");
valuesMap = new HashMap();
valuesMap.put("start",dataSetRow["start"]);
valuesMap.put("end",dataSetRow["end"]);
this.content= localizationTextManager.getLocaleMessage(this.contentKey,valuesMap);
this.contentKey="";":
ReferenceError: "dataSetRow" is not defined. (/report/body/text[
@id="382"]/method[
@name="onCreate"]#4)