summaryrefslogtreecommitdiffstats
path: root/sc
diff options
context:
space:
mode:
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/data/column2.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/sc/source/core/data/column2.cxx b/sc/source/core/data/column2.cxx
index 82f03cc73930..d0d53eadece5 100644
--- a/sc/source/core/data/column2.cxx
+++ b/sc/source/core/data/column2.cxx
@@ -1353,7 +1353,7 @@ SCROW ScColumn::FindNextVisibleRowWithContent(SCROW nRow, bool bForward) const
bool bThere = Search( nRow, nIndex );
if( bThere && !maItems[nIndex].pCell->IsBlank())
return nRow;
- else if(nIndex >= maItems.size())
+ else if((bThere ? nIndex+1 : nIndex) >= maItems.size())
return MAXROW;
else
{