diff options
Diffstat (limited to 'dbaccess/source')
-rw-r--r-- | dbaccess/source/ui/misc/DExport.cxx | 4 | ||||
-rw-r--r-- | dbaccess/source/ui/misc/TokenWriter.cxx | 4 | ||||
-rw-r--r-- | dbaccess/source/ui/tabledesign/TEditControl.cxx | 3 |
3 files changed, 5 insertions, 6 deletions
diff --git a/dbaccess/source/ui/misc/DExport.cxx b/dbaccess/source/ui/misc/DExport.cxx index 577a9a31f2fa..221b38e228ef 100644 --- a/dbaccess/source/ui/misc/DExport.cxx +++ b/dbaccess/source/ui/misc/DExport.cxx @@ -330,13 +330,13 @@ void ODatabaseExport::insertValueIntoColumn() m_pUpdateHelper->updateNull(nPos,pField->GetType()); else { - sal_Int32 nNumberFormat = 0; - double fOutNumber = 0.0; OSL_ENSURE((nNewPos) < static_cast<sal_Int32>(m_vColumnTypes.size()),"Illegal index for vector"); if (m_vColumnTypes[nNewPos] != DataType::VARCHAR && m_vColumnTypes[nNewPos] != DataType::CHAR && m_vColumnTypes[nNewPos] != DataType::LONGVARCHAR ) { RTL_LOGFILE_CONTEXT_TRACE( aLogger, "ODatabaseExport::insertValueIntoColumn != DataType::VARCHAR" ); ensureFormatter(); + sal_Int32 nNumberFormat = 0; + double fOutNumber = 0.0; bool bNumberFormatError = false; if ( m_pFormatter && m_sNumToken.Len() ) { diff --git a/dbaccess/source/ui/misc/TokenWriter.cxx b/dbaccess/source/ui/misc/TokenWriter.cxx index 93f46a8cdf62..311eec0c00ed 100644 --- a/dbaccess/source/ui/misc/TokenWriter.cxx +++ b/dbaccess/source/ui/misc/TokenWriter.cxx @@ -1005,13 +1005,13 @@ void OHTMLImportExport::WriteCell( sal_Int32 nFormat,sal_Int32 nWidthPixel,sal_I aStrTD = aStrTD + "="; aStrTD = aStrTD + pChar; - double fVal = 0.0; - Reference< ::com::sun::star::util::XNumberFormatsSupplier > xSupplier = m_xFormatter->getNumberFormatsSupplier(); SvNumberFormatsSupplierObj* pSupplierImpl = SvNumberFormatsSupplierObj::getImplementation( xSupplier ); SvNumberFormatter* pFormatter = pSupplierImpl ? pSupplierImpl->GetNumberFormatter() : NULL; if(pFormatter) { + double fVal = 0.0; + try { fVal = m_xFormatter->convertStringToNumber(nFormat,rValue); diff --git a/dbaccess/source/ui/tabledesign/TEditControl.cxx b/dbaccess/source/ui/tabledesign/TEditControl.cxx index 41d944c080d7..48ae96c47928 100644 --- a/dbaccess/source/ui/tabledesign/TEditControl.cxx +++ b/dbaccess/source/ui/tabledesign/TEditControl.cxx @@ -1781,7 +1781,6 @@ void OTableEditorCtrl::SetPrimaryKey( sal_Bool bSet ) // Evtl. vorhandene Primary Keys loeschen MultiSelection aDeletedPrimKeys; aDeletedPrimKeys.SetTotalRange( Range(0,GetRowCount()) ); - long nIndex = 0; ::std::vector< ::boost::shared_ptr<OTableRow> >::const_iterator aIter = m_pRowList->begin(); ::std::vector< ::boost::shared_ptr<OTableRow> >::const_iterator aEnd = m_pRowList->end(); @@ -1800,7 +1799,7 @@ void OTableEditorCtrl::SetPrimaryKey( sal_Bool bSet ) aInsertedPrimKeys.SetTotalRange( Range(0,GetRowCount()) ); if( bSet ) { - nIndex = FirstSelectedRow(); + long nIndex = FirstSelectedRow(); while( nIndex >= 0 && nIndex < static_cast<long>(m_pRowList->size()) ) { ////////////////////////////////////////////////////////////////////// |