Issue 76158 - Process CSS of HTML files generated by some report engines that predicate to write Excel files.
Summary: Process CSS of HTML files generated by some report engines that predicate to ...
Status: CLOSED DUPLICATE of issue 70981
Alias: None
Product: Calc
Classification: Application
Component: open-import (show other issues)
Version: OOo 2.2
Hardware: All All
: P3 Trivial (vote)
Target Milestone: ---
Assignee: requirements
QA Contact: issues@sc
Keywords: oooqa
Depends on:
Reported: 2007-04-06 20:08 UTC by shartley07
Modified: 2013-08-07 15:12 UTC (History)
4 users (show)

See Also:
Latest Confirmation in: ---
Developer Difficulty: ---

GL Report that doesnt open correctly in OpenOffice (19.28 KB, application/
2007-04-06 20:09 UTC, shartley07
no flags Details
part of File Open dialog with choosen filter (2.77 KB, image/png)
2007-04-12 23:07 UTC, cno
no flags Details
So everyone can see the difference (104.32 KB, text/plain)
2007-04-12 23:25 UTC, shartley07
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description shartley07 2007-04-06 20:08:38 UTC
I have an excel file that is exported by IntAcct accounting software.  When I 
open the file in Excel, the table it show has formating in it.  It has grey 
title bars, columns line up, etc.  When it is opened in OpenOffice, not of 
that appears and it prints incorrectly.  Also, if I try to "save as" it wants 
to save the document as an HTML file.  I can email the file to you.  Please 
help.  I am trying to move a company from Office to OpenOffice and these 
little things are becoming prohibitive.
Comment 1 shartley07 2007-04-06 20:09:40 UTC
Created attachment 44259 [details]
GL Report that doesnt open correctly in OpenOffice
Comment 2 cno 2007-04-07 11:05:08 UTC
Seems to be a special xls.
Opening in Excel and choosing Save|As gives html-format as well (as default).
Saving as .xls creates a file that opens in OOo as expected.
I've no clue about what causes this.
Comment 3 kpalagin 2007-04-09 09:41:14 UTC
Confirming with OO2.2 on WinXP - there seems to be no way to force the file 
open in Calc, instead the file open in Writer (loosing most of the formatting).
Excel opens the file just fine.
Comment 4 shartley07 2007-04-09 17:17:16 UTC
Couple of things

1) We do not have MS Office installed on these machines
2) The file is created as an export feature out of our ASP's web application
3) The software vendor is unwilling to modify the export procedures
4) This is a new company, and we are trying to NOT install office on any 
5) OpenOffice is really the direction we want to go

All of this being said, is there really NO way to do this?

Currently the users access the web site, select export, when they are asked to 
save or open they select "open".  I know I can not add many more steps into 
their routine without resistance.

As great a product as OpenOffice is, there should be some way to overcome this 
issue.  Is this something that will have to wait until the next release of OO?  
Can we ask that this get added?  Any help or feedback is greatly appreciated.  
Please keep up the great work.  I 
Comment 5 cno 2007-04-10 08:18:11 UTC
> 3) The software vendor is unwilling to modify the export procedures
> 5) OpenOffice is really the direction we want to go
> All of this being said, is there really NO way to do this?

Some clarity about what is special with this .xls file could help.
Maybe someone at knows it.
If not, the vendor should be the one to give more info.
Once this is known, it must be considered how easy or complicated the thing is, IMO.
Comment 6 frank 2007-04-10 15:48:50 UTC

not a defect. The file attached is indeed a HTML file. This file contains CSS
Style data which can not be interpreted by Calc for now. So this Issue is an
enhancement for CSS import of HTML files.

To open such non xls files directly with Calc, you may bind .XLS to scalc
instead of soffice.

Comment 7 kpalagin 2007-04-10 16:00:38 UTC
Even if I try opening the file via File - Open and select any of spreadsheet 
formats it will open in Writer.
Comment 8 frank 2007-04-10 16:26:20 UTC

use HTML Document Calc or the Webquery filter in the spreadsheet
section of the filter selector box.

Comment 9 shartley07 2007-04-10 18:39:09 UTC
Thank you all for your help and quick replies - Microsoft should take notes...

The file does open in scalc and in swriter, but it loses all of the formatting 
that is containted in the document.  when the file is opened in office, it has 
gray scaling, and such (no graphics) but when it is opened in OO, all of that 
seems to be gone.   And users love their pretty little reports - lol.

I am not sure I understand the "filter" concept described below.  Could someone 
please expand on that for me?  I am not much of a "user"  OO works great for me 
since I dont do much.  I am techie, and trying to "sell" 2 different companies 
on leaving Microsoft. 

Again, all help is greatly appreciated.  Thank you in advance.
Comment 10 frank 2007-04-12 12:40:49 UTC

OOo has a build in file type detection. So text files will open always in
Writer, HTML Fiels in Writer/Web. Even if they do not have the propper extension
as your Example shows. The XLS file you've attached isn't a real Excel file but
an HTML file. So it opens in Writer/Web by default. If you choose the HTML
Import filter for Calc in the File Open Dialog under Filter Type you force the
file to be opened in Calc. That's the whole mystic with filters for file types.

Comment 11 shartley07 2007-04-12 17:00:34 UTC
Hello again,

Thank you everyone who has posted a reply

I would like to clarify a few things

1) the file is created as an .xls file evenb though it is more of an HTML file
2) scalc does open the file after the user is prompted to open/save the file 
and they select open
3) the data in the file does show up (ie the numbers)

The problem the user has is the formatting is "gone" or not being processed.  
So instead of a nice looking report (as it appears in Excel) they get this ugly 
unformatted document.  This happens whether you save the file and open it, or 
if you open scalc and then select file>open. 

I am not sure I am "getting" the filter aspect that has been referred to here.  
I have tried looking for a file>open>filter and the only thing i notice is 
the "file type" that you can select to be "html" but the file is not a ".html" 
it is a ".xls"

If I have the user "save" instead of "open" and then rename the file to ".html" 
and they open it at that point, it opens in swriter but still the formatting is 
wrong.  If they open scalc and then select the file, it still opens in swriter 
and shows up wrong.  If it is opened in internet explorer (the html default) it 
shows up fine in there.

Trying to get the users to do "extra" steps to use OO2.2 is going to be 
difficult.  For some reason, OO is not processing the html formatting correctly.

As an ".xls" file- IE7 doesnt want to open it, but firefox will and does 
display it correctly. 

As an ".html" file- IE7, firefox, word and excel display the file correctly.

OpenOffice does open it BUT DOESNT display it correctly, it doesnt seem to like 
the HTML.

If I have missed the "filter" process by not understanding, then someone please 
help me.  The only "filter" option I see in scalc is tools>xml filter settings 
but I dont understand if that is the correct place or what to change/add there.

Again thanks in advance, I am really trying to get this figured out but I seem 
to be missing the boat...
Comment 12 ooo 2007-04-12 17:45:49 UTC
As mentioned previously in #desc7 all the formatting is done in CSS. Calc
imports HTML but currently does not process any CSS attribution.

Forwarding to 'requirements'.
Comment 13 cno 2007-04-12 23:03:44 UTC
Hi ?,
I create an attachment with a screenprint of the settings in the file open
dialog, that Frank wrote about.
Thus you can open the file in Calc.
I can't judge if the formatting is OK for you.
Comment 14 cno 2007-04-12 23:07:00 UTC
Created attachment 44390 [details]
part of File Open dialog with choosen filter
Comment 15 shartley07 2007-04-12 23:25:37 UTC
Created attachment 44391 [details]
So everyone can see the difference
Comment 16 shartley07 2007-04-12 23:29:12 UTC
I have posted some screen prints to show the difference.  Thank you everyone 
for your time and assistance.  This would not be a big deal if it were 1 report 
run occassionaly.  But the users are creating reports all day out of the 
software that when opened in OO, they look BAD.  The estimate is about 100 
reports a week.  If they have to add a couple of steps to each time they want 
to run a report, they WILL NOT stay with OO and will go back to MSOffice.  I 
REALLY DONT want that.

Again, Thank you everyone!
Comment 17 lohmaier 2007-04-15 13:39:27 UTC
Comment 18 lohmaier 2007-04-15 13:41:50 UTC
Hmm - why didn't it flag as duplicate? second attempt...

*** This issue has been marked as a duplicate of 70981 ***
Comment 19 lohmaier 2007-04-15 13:42:31 UTC
and closing.