diff options
-rw-r--r-- | sc/source/core/tool/interpr6.cxx | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sc/source/core/tool/interpr6.cxx b/sc/source/core/tool/interpr6.cxx index 4d5febc210e1..a9b48d061b3c 100644 --- a/sc/source/core/tool/interpr6.cxx +++ b/sc/source/core/tool/interpr6.cxx @@ -670,6 +670,13 @@ void ScInterpreter::IterateParameters( ScIterFunc eFunc, bool bTextAsZero ) return; } + if ( ( ( mnSubTotalFlags & SubtotalFlags::IgnoreFiltered ) && + pDok->RowFiltered( aAdr.Row(), aAdr.Tab() ) ) || + ( ( mnSubTotalFlags & SubtotalFlags::IgnoreHidden ) && + pDok->RowHidden( aAdr.Row(), aAdr.Tab() ) ) ) + { + break; + } if ( nGlobalError != FormulaError::NONE && ( eFunc == ifCOUNT2 || eFunc == ifCOUNT || ( mnSubTotalFlags & SubtotalFlags::IgnoreErrVal ) ) ) { @@ -678,13 +685,6 @@ void ScInterpreter::IterateParameters( ScIterFunc eFunc, bool bTextAsZero ) ++nCount; break; } - if ( ( ( mnSubTotalFlags & SubtotalFlags::IgnoreFiltered ) && - pDok->RowFiltered( aAdr.Row(), aAdr.Tab() ) ) || - ( ( mnSubTotalFlags & SubtotalFlags::IgnoreHidden ) && - pDok->RowHidden( aAdr.Row(), aAdr.Tab() ) ) ) - { - break; - } ScRefCellValue aCell(*pDok, aAdr); if (!aCell.isEmpty()) { |