mirror of https://github.com/apache/poi.git
git-svn-id: https://svn.apache.org/repos/asf/jakarta/poi/trunk@513605 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
71e5ccf8e2
commit
ffd6b3f8a0
|
@ -750,11 +750,14 @@ public class HSSFWorkbook
|
|||
NameRecord r = null;
|
||||
while ((r = (NameRecord) workbook.findNextRecordBySid(NameRecord.sid, index)) != null)
|
||||
{
|
||||
int nameRecordSheetIndex = workbook.getSheetIndexFromExternSheetIndex(r.getEqualsToIndexToSheet() - 1);
|
||||
if (isRowColHeaderRecord( r ) && nameRecordSheetIndex == sheetIndex)
|
||||
{
|
||||
return index;
|
||||
}
|
||||
int indexToSheet = r.getEqualsToIndexToSheet() -1;
|
||||
if(indexToSheet > -1) { //ignore "GLOBAL" name records
|
||||
int nameRecordSheetIndex = workbook.getSheetIndexFromExternSheetIndex(indexToSheet);
|
||||
if (isRowColHeaderRecord( r ) && nameRecordSheetIndex == sheetIndex)
|
||||
{
|
||||
return index;
|
||||
}
|
||||
}
|
||||
index++;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue