Skip to main content



      Home
Home » Archived » BIRT » Birt 4.3.1 - Different output on XLS and XLSX for crosstab(Refers to https://bugs.eclipse.org/bugs/show_bug.cgi?id=447399)
Birt 4.3.1 - Different output on XLS and XLSX for crosstab [message #1621017] Tue, 17 February 2015 11:00 Go to next message
Eclipse UserFriend
Hello,

I have a report containing two crosstabs. Each crosstab contains a grid with multiple rows and columns.
If I save the report in XLS, the output corresponds to the way the crosstab worked.
However, when saving the report in XLSX, each grid is merged into a single cell in the XLSX file. The task for the report demands it be in XLSX format.
I know the bug was reported on bugs.eclipse.org, with the ID 447399.

Has anyone however found a workaround to this?
Re: Birt 4.3.1 - Different output on XLS and XLSX for crosstab [message #1621388 is a reply to message #1621017] Tue, 17 February 2015 16:44 Go to previous messageGo to next message
Eclipse UserFriend
XLSX is a totally different emitter. It's the "spudsoft" emitter. I'm not totally familiar with all of the options available with that plugin, but you might take a look at what's available: https://bitbucket.org/yaytay/spudsoft-birt-excel-emitters/wiki/UserProperties. One thing you could do would be to use the Free BIRT iHub F-Type Server to produce your XLS and XLSX outputs.
Re: Birt 4.3.1 - Different output on XLS and XLSX for crosstab [message #1623581 is a reply to message #1621388] Thu, 19 February 2015 02:18 Go to previous messageGo to next message
Eclipse UserFriend
Thank you for your answer, Michael!

The Free BIRT iHub F-Type Server might not be an option, as the conversion of the BIRT report has to be included into a web application for the client.

However, could you provide a bit more insight on how to use the Excel emitters?
I tried like this

if(reportContext.getOutputFormat().equalsIgnoreCase("xlsx")){
	 reportContext.getDesignHandle().setProperty("ExcelEmitter.ExtractMode", "true");
}


This code is added in the script of the layout of the page, on the initialize action.
But it didn't work. I also tried with the property and the set value in and out of the double quotes, in all combinations.

The ExcelEmitter.ExtractMode seems to show something that might work.

Online research on scripting did not provide that much information.
Re: Birt 4.3.1 - Different output on XLS and XLSX for crosstab [message #1624209 is a reply to message #1623581] Thu, 19 February 2015 11:37 Go to previous message
Eclipse UserFriend
Found solution:
At first I had the following crosstab, drawn with blue, with a grid inside it, drawn with gray.
index.php/fa/20918/0/

In the XLSX file, the gray grid would be outputted as a single cell, with all grid elements merged into one text.

As Jim Talbut says here, this is caused by the fact that nested elemented are handled with a "one cell in = one cell out" rule, which overrides everything else.

So, my solution: I added another grid, marked with red, like so:
index.php/fa/20919/0/

So, just another grid with 1 row and 1 column, i.e., 1 cell. The outer red grid is treated with the "one cell in = one cell out" rule, and the inner gray grid is displayed correctly in the XLSX file.

Perhaps this will help someone else in the future. Cheers!
  • Attachment: initial.png
    (Size: 28.97KB, Downloaded 1825 times)
  • Attachment: solution.png
    (Size: 5.76KB, Downloaded 1823 times)

[Updated on: Thu, 19 February 2015 11:37] by Moderator

Previous Topic:FreeFormHandle trouble
Next Topic:Birt 4.3.1 - Crosstab - Hiding default empty rows
Goto Forum:
  


Current Time: Fri Mar 21 07:55:26 EDT 2025

Powered by FUDForum. Page generated in 0.04492 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top