Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » BIRT » Problem with Maximo getHtmlString(Problem with Maximo getHtmlString)
Problem with Maximo getHtmlString [message #990105] Mon, 10 December 2012 16:55 Go to next message
Brian McMahon is currently offline Brian McMahon
Messages: 8
Registered: July 2012
Location: University of Delaware
Junior Member
Hello:

I have a maximo birt problem.

I have a work order that is causing an error in a the BIRT report woprint.rptdesign.
The problem has been narrowed down to the getHtmlString method. If I remark out the line everything works fine but no long description. If I replace the getHtmlString with getString it works but formating is not perfect. I have looked at the data and do not see anything worse than CRLF (0D0A) in the long description. I would like to go further, but I can not find where the getHtmlString method is located.

Question is: Is the method getHtmlString a Maximo method or Birt or Javascript, where is it located, can it be fixed or overwritten?

This is problem is ocurring where it is getting the long description.


// Long Description
longDescDataSet = MXReportDataSetProvider.create(this.getDataSource().getName(), "longDescDataSet");
longDescDataSet.open();

longDescSQL = "select longdescription.ldtext "
+ "from longdescription "
+ "where longdescription.ldownertable='WORKORDER' and longdescription.ldownercol='DESCRIPTION' "
+ "and longdescription.ldkey=" + row["workorderid"];

longDescDataSet.setQuery(longDescSQL);

if(longDescDataSet.fetch()) {
row["longdesc"] = longDescDataSet.getHtmlString("ldtext");
}

longDescDataSet.close();
// End Long Description



Thank you

Re: Problem with Maximo getHtmlString [message #990511 is a reply to message #990105] Wed, 12 December 2012 15:17 Go to previous message
Brian McMahon is currently offline Brian McMahon
Messages: 8
Registered: July 2012
Location: University of Delaware
Junior Member
Found the problem.

The method getHtmlString is indeed a Maximo method. It is in the MXReportDataSetImpl class (com.ibm.tivoli.maximo.report.script.MXReportDataSetImpl).

The getHtmlString method seems to only expect rich text. The data that is causing issues in the long description field is not rich text, nor does it have any html tags. It is plain ASCII text that does have the characters -> in it. The characters -> are causing problems within this getHtmlString method.

I guess there are two solutions each of which means changes to the out of the box report:

1. Make sure the long description is in the correct format prior to the getHtmlString method call.

2. Do not use the getHtmlString method.


Thank you


Previous Topic:Image DPI
Next Topic:Data type characteristics
Goto Forum:
  


Current Time: Wed Jul 23 20:25:51 EDT 2014

Powered by FUDForum. Page generated in 0.03213 seconds