From 190dec5874fb8e644944c6d3027470fdc8844b38 Mon Sep 17 00:00:00 2001 From: Shawn Laubach Date: Wed, 9 Jul 2003 20:20:22 +0000 Subject: [PATCH] Applied the pertinent patch for bug #21439 by Paul Pound to get the header/footer from the sheet and not a chart. git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@353199 13f79535-47bb-0310-9956-ffa450edef68 --- src/java/org/apache/poi/hssf/model/Sheet.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/java/org/apache/poi/hssf/model/Sheet.java b/src/java/org/apache/poi/hssf/model/Sheet.java index c481665424..b99989cc90 100644 --- a/src/java/org/apache/poi/hssf/model/Sheet.java +++ b/src/java/org/apache/poi/hssf/model/Sheet.java @@ -249,15 +249,15 @@ public class Sheet implements Model { retval.printGridlines = (PrintGridlinesRecord) rec; } - else if ( rec.getSid() == HeaderRecord.sid ) + else if ( rec.getSid() == HeaderRecord.sid && bofEofNestingLevel == 1) { retval.header = (HeaderRecord) rec; } - else if ( rec.getSid() == FooterRecord.sid ) + else if ( rec.getSid() == FooterRecord.sid && bofEofNestingLevel == 1) { retval.footer = (FooterRecord) rec; } - else if ( rec.getSid() == PrintSetupRecord.sid ) + else if ( rec.getSid() == PrintSetupRecord.sid && bofEofNestingLevel == 1) { retval.printSetup = (PrintSetupRecord) rec; } -- 2.39.5