diff options
Diffstat (limited to 'dbaccess/source/ui/misc/WCPage.cxx')
-rw-r--r-- | dbaccess/source/ui/misc/WCPage.cxx | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/dbaccess/source/ui/misc/WCPage.cxx b/dbaccess/source/ui/misc/WCPage.cxx index 63a910929836..85804dec9d0c 100644 --- a/dbaccess/source/ui/misc/WCPage.cxx +++ b/dbaccess/source/ui/misc/WCPage.cxx @@ -227,7 +227,8 @@ sal_Bool OCopyTable::LeavePage() if ( !aNameCheck.isNameValid( m_edTableName.GetText(), aErrorInfo ) ) { aErrorInfo.append( SQLExceptionInfo::SQL_CONTEXT, String( ModuleRes( STR_SUGGEST_APPEND_TABLE_DATA ) ) ); - ::dbaui::showError( aErrorInfo, m_pParent, m_pParent->m_xFactory ); + m_pParent->showError(aErrorInfo.get()); + return sal_False; } @@ -245,7 +246,8 @@ sal_Bool OCopyTable::LeavePage() sal_Int32 nMaxLength = xMeta->getMaxTableNameLength(); if ( nMaxLength && sTable.getLength() > nMaxLength ) { - ErrorBox(this, ModuleRes(ERROR_INVALID_TABLE_NAME_LENGTH)).Execute(); + String sError(ModuleRes(STR_INVALID_TABLE_NAME_LENGTH)); + m_pParent->showError(sError); return sal_False; } @@ -256,8 +258,7 @@ sal_Bool OCopyTable::LeavePage() String aInfoString( ModuleRes(STR_WIZ_PKEY_ALREADY_DEFINED) ); aInfoString += String(' '); aInfoString += String(m_pParent->m_aKeyName); - InfoBox aNameInfoBox( this, aInfoString ); - aNameInfoBox.Execute(); + m_pParent->showError(aInfoString); return sal_False; } } @@ -288,7 +289,8 @@ sal_Bool OCopyTable::LeavePage() if(!m_pParent->m_sName.getLength()) { - ErrorBox(this, ModuleRes(ERROR_INVALID_TABLE_NAME)).Execute(); + String sError(ModuleRes(STR_INVALID_TABLE_NAME)); + m_pParent->showError(sError); return sal_False; } @@ -367,9 +369,8 @@ sal_Bool OCopyTable::checkAppendData() if ( !xTable.is() ) { - ErrorBox( this, ModuleRes( ERROR_INVALID_TABLE_NAME ) ).Execute(); - // TODO: shouldn't this be some kind of showError? In case of the UNO service for this wizard, - // shouldn't this even be a usage of the service's interaction handler? + String sError(ModuleRes(STR_INVALID_TABLE_NAME)); + m_pParent->showError(sError); return sal_False; } return sal_True; |