User: obo Date: 06/01/19 07:43:43 Modified: /dba/dbaccess/source/ui/misc/ RtfReader.cxx
Log: INTEGRATION: CWS dba202e (1.16.56); FILE MERGED 2006/01/03 09:43:27 oj 1.16.56.1: #i59833# exception caught File Changes: Directory: /dba/dbaccess/source/ui/misc/ ======================================== File [changed]: RtfReader.cxx Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/misc/RtfReader.cxx?r1=1.17&r2=1.18 Delta lines: +14 -31 --------------------- --- RtfReader.cxx 16 Jan 2006 15:29:07 -0000 1.17 +++ RtfReader.cxx 19 Jan 2006 15:43:40 -0000 1.18 @@ -77,9 +77,6 @@ #ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTYPES_HPP_ #include <com/sun/star/util/XNumberFormatTypes.hpp> #endif -#ifndef _DBAUI_SQLMESSAGE_HXX_ -#include "sqlmessage.hxx" -#endif #ifndef DBACCESS_SHARED_DBUSTRINGS_HRC #include "dbustrings.hrc" #endif @@ -169,6 +166,7 @@ rInput.Seek(STREAM_SEEK_TO_BEGIN); rInput.ResetError(); SvParserState eParseState = SvRTFParser::CallParser(); + SetColumnTypes(m_pColumnList,m_pInfoMap); return m_bFoundTable ? eParseState : SVPAR_ERROR; } // --------------------------------------------------------------------------- @@ -219,26 +217,15 @@ if(!m_xTable.is()) // erste Zeile als Header verwenden m_bError = !CreateTable(nToken); else + { try { m_xResultSetUpdate->moveToInsertRow(); // sonst neue Zeile anh"angen } catch(SQLException& e) - ////////////////////////////////////////////////////////////////////// // UpdateFehlerbehandlung { - if(!m_bDontAskAgain) - { - String aMsg(e.Message); - aMsg += '\n'; - aMsg += String(ModuleRes(STR_QRY_CONTINUE)); - OSQLMessageBox aBox(NULL, String(ModuleRes(STR_STAT_WARNING)), - aMsg, WB_YES_NO | WB_DEF_NO, OSQLMessageBox::Warning); - - if (aBox.Execute() == RET_YES) - m_bDontAskAgain = TRUE; - else - m_bError = TRUE; + showErrorDialog(e); } } break; @@ -254,7 +241,15 @@ break; case RTF_CELL: { + try + { insertValueIntoColumn(); + } + catch(SQLException& e) + // UpdateFehlerbehandlung + { + showErrorDialog(e); + } m_nColumnPos++; m_sTextToken.Erase(); } @@ -273,19 +268,7 @@ ////////////////////////////////////////////////////////////////////// // UpdateFehlerbehandlung { - if(!m_bDontAskAgain) - { - String aMsg(e.Message); - aMsg += '\n'; - aMsg += String(ModuleRes(STR_QRY_CONTINUE)); - OSQLMessageBox aBox(NULL, String(ModuleRes(STR_STAT_WARNING)), - aMsg, WB_YES_NO | WB_DEF_NO, OSQLMessageBox::Warning); - - if (aBox.Execute() == RET_YES) - m_bDontAskAgain = TRUE; - else - m_bError = TRUE; - } + showErrorDialog(e); } m_nColumnPos = 0; break; --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
