View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Stephane Rodriguez[_7_] Stephane Rodriguez[_7_] is offline
external usenet poster
 
Posts: 1
Default Excel 4.0 parser


You'll find many of the required information in this PDF document fro
open office : http://sc.openoffice.org/excelfileformat.pdf (1MB).

In essence, you should not access a fix offset for many reasons. Th
first being that the internal Excel file format is inside an OLE strea
whose compound size is variable. And that this offset will becom
meaningless based on many actions done on the Excel file.

In short, you should instead open the OLE stream using the appropriat
WIN32 OLE API, and then you can read Excel records one by one. Eac
record is a 2-byte identifier, followed by a 2-byte length of th
associated buffer, then followed by the buffer itself. Each time th
buffer is over 8228 bytes, special continue records are used. Yo
should easily get access to numbers, if you know how to decode them
But accessing strings should be more difficult since they are shared i
a global dictionary. And that unfolds even more details to worr
about..

--
Stephane Rodrigue

-----------------------------------------------------------------------
Stephane Rodriguez's Profile: http://www.hightechtalks.com/m33
View this thread: http://www.hightechtalks.com/t229359