Tag: cws_src680_dba30 User: fs Date: 05/12/22 01:19:32 Modified: /dba/dbaccess/source/ui/inc/ dbu_tbl.hrc /dba/dbaccess/source/ui/tabledesign/ TableController.cxx, table.src
Log: tweaking some table-design related error messages File Changes: Directory: /dba/dbaccess/source/ui/inc/ ======================================= File [changed]: dbu_tbl.hrc Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/inc/dbu_tbl.hrc?r1=1.5&r2=1.5.14.1 Delta lines: +5 -3 ------------------- --- dbu_tbl.hrc 8 Sep 2005 15:50:48 -0000 1.5 +++ dbu_tbl.hrc 22 Dec 2005 09:19:29 -0000 1.5.14.1 @@ -4,9 +4,9 @@ * * $RCSfile: dbu_tbl.hrc,v $ * - * $Revision: 1.5 $ + * $Revision: 1.5.14.1 $ * - * last change: $Author: rt $ $Date: 2005/09/08 15:50:48 $ + * last change: $Author: fs $ $Date: 2005/12/22 09:19:29 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -92,6 +92,8 @@ #define STR_CHANGE_COLUMN_TYPE RID_STR_TBL_START + 50 #define STR_CHANGE_COLUMN_DESCRIPTION RID_STR_TBL_START + 51 #define STR_CHANGE_COLUMN_ATTRIBUTE RID_STR_TBL_START + 52 +#define STR_TABLEDESIGN_SAVE_ERROR RID_STR_TBL_START + 53 +#define STR_TABLEDESIGN_COULD_NOT_DROP_COL RID_STR_TBL_START + 54 // please adjust checking before insert new strings Directory: /dba/dbaccess/source/ui/tabledesign/ =============================================== File [changed]: TableController.cxx Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/tabledesign/TableController.cxx?r1=1.99.16.1&r2=1.99.16.2 Delta lines: +27 -6 -------------------- --- TableController.cxx 12 Dec 2005 08:03:16 -0000 1.99.16.1 +++ TableController.cxx 22 Dec 2005 09:19:29 -0000 1.99.16.2 @@ -4,9 +4,9 @@ * * $RCSfile: TableController.cxx,v $ * - * $Revision: 1.99.16.1 $ + * $Revision: 1.99.16.2 $ * - * last change: $Author: oj $ $Date: 2005/12/12 08:03:16 $ + * last change: $Author: fs $ $Date: 2005/12/22 09:19:29 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -160,6 +160,10 @@ #include "UITools.hxx" #endif +#ifndef _CPPUHELPER_EXC_HLP_HXX_ +#include <cppuhelper/exc_hlp.hxx> +#endif + extern "C" void SAL_CALL createRegistryInfo_OTableControl() { static ::dbaui::OMultiInstanceAutoRegistration< ::dbaui::OTableController > aAutoRegistration; @@ -527,7 +531,10 @@ OSL_ENSURE(sal_False, "OTableController::doSaveDoc: table could not be inserted (caught a generic exception)!"); } + if ( aInfo.isValid() ) + aInfo.prepend( String( ModuleRes( STR_TABLEDESIGN_SAVE_ERROR ) ) ); showError(aInfo); + if (aInfo.isValid() || bError) { if(!bAlter || bNew) @@ -1379,9 +1386,23 @@ continue; } } - Reference<XDrop> xDrop(xColumns,UNO_QUERY); + try + { xDrop->dropByName(*pIter); } + catch (const SQLException&) + { + String sError( ModuleRes( STR_TABLEDESIGN_COULD_NOT_DROP_COL ) ); + sError.SearchAndReplaceAscii( "$column$", *pIter ); + + SQLException aNewException; + aNewException.Message = sError; + aNewException.SQLState = ::rtl::OUString::createFromAscii( "S1000" ); + aNewException.NextException = ::cppu::getCaughtException(); + + throw aNewException; + } + } } } File [changed]: table.src Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/tabledesign/table.src?r1=1.91&r2=1.91.16.1 Delta lines: +15 -4 -------------------- --- table.src 23 Sep 2005 14:18:56 -0000 1.91 +++ table.src 22 Dec 2005 09:19:29 -0000 1.91.16.1 @@ -4,9 +4,9 @@ * * $RCSfile: table.src,v $ * - * $Revision: 1.91 $ + * $Revision: 1.91.16.1 $ * - * last change: $Author: hr $ $Date: 2005/09/23 14:18:56 $ + * last change: $Author: fs $ $Date: 2005/12/22 09:19:29 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -419,6 +419,18 @@ Text [ en-US ] = "The column \"$column$\" could not be changed. Should the column instead be deleted and the new format appended?" ; }; +String STR_TABLEDESIGN_SAVE_ERROR +{ + Text [ de ] = "Fehler beim Speichern des Tabellenentwurfes"; + Text [ en-US ] = "Error while saving the table design"; +}; + +String STR_TABLEDESIGN_COULD_NOT_DROP_COL +{ + Text [ de ] = "Die Spalte $column$ konnte nicht gelöscht werden."; + Text [ en-US ] = "The column $column$ could not be deleted."; +}; + QueryBox TABLE_DESIGN_ALL_ROWS_DELETED { Buttons = WB_YES_NO_CANCEL ; @@ -467,4 +479,3 @@ Text [ de ] = "Feldattribut ändern"; Text [ en-US ] = "change field attribute"; }; - --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
