https://bugs.documentfoundation.org/show_bug.cgi?id=94382

Julien Nabet <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]

--- Comment #6 from Julien Nabet <[email protected]> ---
With this change, it seems to work:
diff --git a/sc/source/filter/excel/excel.cxx
b/sc/source/filter/excel/excel.cxx
index b21ca5f..249fb62 100644
--- a/sc/source/filter/excel/excel.cxx
+++ b/sc/source/filter/excel/excel.cxx
@@ -120,7 +120,7 @@ FltError ScFormatFilterPluginImpl::ScImportExcel(
SfxMedium& rMedium, ScDocument
     {
         pBookStrm->SetBufferSize( 0x8000 );     // still needed?

-        XclImpRootData aImpData( eBiff, rMedium, xRootStrg, *pDocument,
RTL_TEXTENCODING_MS_1252 );
+        XclImpRootData aImpData( eBiff, rMedium, xRootStrg, *pDocument,
RTL_TEXTENCODING_MS_936);
         std::unique_ptr< ImportExcel > xFilter;
         switch( eBiff )
         {

Of course, the change is wrong but it seemed to me a good start to search.

I added some traces in ImportExcel::Read() in sc/source/filter/excel/read.cxx
and had only these:
- case Z_Biff5TPre, nOpcode: 516 (0x0204 = EXC_ID3_LABEL)
- case Z_Biff5TPre, nOpcode: 10 (0x000A)
- case Z_Biff5T, nOpcode: 516
- case Z_Biff5T, nOpcode: 10

So indeed, if we don't enter "case 0x42:  Codepage(); break;", I don't know how
we can retrieve the right codepage/encoding

I tried to take a look to xls specs
https://msdn.microsoft.com/en-us/library/office/cc313154%28v=office.12%29.aspx.
No hints :-(

Of course, there may be some code we may call to have dialog box proposing
encoding but, if Excel5 can display correctly the file, certainly the encoding
info are stored somewhere.

Eike: thought you might be interested/have some idea

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to