diff options
author | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2011-08-03 00:25:57 +0200 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2011-08-03 02:38:50 +0200 |
commit | 867981e5c1b2bae8cc0ab511359029ad5ebbf56d (patch) | |
tree | be0902d9fb23e193a1fadaaab66257fee7955ed7 /sc | |
parent | 1a82e945cda420aabb37cadbb283fb83252385b7 (diff) |
fix for fdo#39151: set correct table number in local db data
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/core/data/table2.cxx | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/sc/source/core/data/table2.cxx b/sc/source/core/data/table2.cxx index 8c113ce3079e..b079128b2154 100644 --- a/sc/source/core/data/table2.cxx +++ b/sc/source/core/data/table2.cxx @@ -768,7 +768,15 @@ void ScTable::CopyToTable(SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2, return; if (pDBDataNoName) - pDestTab->SetAnonymousDBData(new ScDBData(*pDBDataNoName)); + { + ScDBData* pNewDBData = new ScDBData(*pDBDataNoName); + SCCOL aCol1, aCol2; + SCROW aRow1, aRow2; + SCTAB aTab; + pNewDBData->GetArea(aTab, aCol1, aRow1, aCol2, aRow2); + pNewDBData->MoveTo(pDestTab->nTab, aCol1, aRow1, aCol2, aRow2); + pDestTab->SetAnonymousDBData(pNewDBData); + } // Charts muessen beim Ein-/Ausblenden angepasst werden ScChartListenerCollection* pCharts = pDestTab->pDocument->GetChartListenerCollection(); |