Bug 13500

Summary: [PATCH] Record 1C1h (RecalcId)
Product: POI Reporter: Luc Girardin <luc.girardin>
Component: HSSFAssignee: POI Developers List <dev>
Status: RESOLVED FIXED    
Severity: major CC: luc.girardin
Priority: P3    
Version: 2.0-dev   
Target Milestone: ---   
Hardware: All   
OS: All   
Attachments: Patch to Workbook and RecordFactory classes
RecalcIdRecord.java

Description Luc Girardin 2002-10-10 16:13:20 UTC
This 1C1h record contains an ID that marks when a worksheet was last 
recalculated. It's an optimization Excel uses to determine if it needs to  
recalculate the spreadsheet when it's opened. So far, only the two values 
<code>0xC1 0x01 0x00 0x00 0x80 0x38 0x01 0x00</code> (do not recalculate) and 
<code>0xC1 0x01 0x00 0x00 0x60 0x69 0x01 0x00</code> have been seen. I did try 
to figure out what the 8 bytes of data could represent, without success. 
Removing all 0x1c1 records when saving the workbook solves the problem when 
dealing with cells that reference other cells: this forces Excel to recompute 
every cell.
Comment 1 Luc Girardin 2002-10-10 16:15:37 UTC
Created attachment 3412 [details]
Patch to Workbook and RecordFactory classes
Comment 2 Luc Girardin 2002-10-10 16:16:55 UTC
Created attachment 3413 [details]
RecalcIdRecord.java
Comment 3 Andy Oliver 2002-10-24 23:59:56 UTC
I hope you resubmit this, but after applying it the SST Record unit test fails.

Please run ./build.sh clean compile test, resolve and resubmit.

or run ./build.sh clean compile site 
(then view the html report which has hte stacktrace)

Thanks,

Andy
Comment 4 Andy Oliver 2002-10-25 00:00:20 UTC
I hope you resubmit this, but after applying it the SST Record unit test fails.

Please run ./build.sh clean compile test, resolve and resubmit.

or run ./build.sh clean compile site 
(then view the html report which has hte stacktrace)

Thanks,

Andy
Comment 5 Luc Girardin 2002-10-29 09:46:46 UTC
Hmmm... I did run the JUnit tests (before sending the patch and again today) 
and no error has been detected. I also quickly double-checked the patch I sent 
and it looks complete. Could you please give it another try?
Comment 6 Luc Girardin 2002-11-27 21:47:44 UTC
I did again verify my patch and it seems valid.
Comment 7 Andy Oliver 2002-11-28 19:22:00 UTC
applied.  My appologies.  This must have been during my encoding issue.  It
would be good if you could submit a unit test for the RecalcIdRecord and maybe
even for the conditions for Workbook.  (if Recalc..then bla, if not then bla)
Comment 8 Paul Krause 2002-12-09 20:08:54 UTC
It would appear that when this patch was committed, RecalcIdRecord.java was not 
added to CVS.
Comment 9 Rainer Klute 2002-12-11 19:43:14 UTC
Paul, you are right. I added RecalcIdRecord.java to the CVS.
Comment 10 Jochen Wiedmann 2011-05-03 11:28:17 UTC
This one might also be interesting:

  [RECALCID]
    .reserved = 0x0000
    .engineId = 0x00013880
  [/RECALCID]

Question: How do I create an RecalcIdRecord? The only available constructor requires a RecordInputStream?
Comment 11 Nick Burch 2011-05-04 00:59:59 UTC
(In reply to comment #10)
> This one might also be interesting:
> 
>   [RECALCID]
>     .reserved = 0x0000
>     .engineId = 0x00013880

This means do not recalulcate - see the first comment

> Question: How do I create an RecalcIdRecord? The only available constructor
> requires a RecordInputStream?

Currently you can't add one to a new file. Wouldn't be too hard to add though, please open a new bug if you'd like to work on this