User: kz Date: 05/01/21 09:20:24 Modified: /dba/dbaccess/source/ui/misc/ datasourceconnector.cxx
Log: INTEGRATION: CWS dba22 (1.5.62); FILE MERGED 2005/01/11 15:47:09 fs 1.5.62.3: #i39187# +getDataSourceByName_displayError 2004/12/20 15:26:57 fs 1.5.62.2: moved STR_FILE_DOES_NOT_EXIST from dbu_dlg to dbu_misc 2004/12/20 15:12:34 fs 1.5.62.1: i39187 File Changes: Directory: /dba/dbaccess/source/ui/misc/ ======================================== File [changed]: datasourceconnector.cxx Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/misc/datasourceconnector.cxx?r1=1.5&r2=1.6 Delta lines: +18 -9 -------------------- --- datasourceconnector.cxx 2 Aug 2004 16:08:51 -0000 1.5 +++ datasourceconnector.cxx 21 Jan 2005 17:20:22 -0000 1.6 @@ -101,6 +101,15 @@ #ifndef _VCL_STDTEXT_HXX #include <vcl/stdtext.hxx> #endif +#ifndef SVTOOLS_FILENOTATION_HXX +#include <svtools/filenotation.hxx> +#endif +#ifndef _DBU_MISC_HRC_ +#include "dbu_misc.hrc" +#endif +#ifndef _DBAUI_MODULE_DBU_HXX_ +#include "moduledbu.hxx" +#endif //......................................................................... namespace dbaui @@ -115,6 +124,7 @@ using namespace ::com::sun::star::beans; using namespace ::com::sun::star::container; using namespace ::dbtools; + using ::svt::OFileNotation; //===================================================================== //= ODatasourceConnector @@ -168,16 +178,15 @@ return xConnection; // get the data source - Reference< XDataSource > xDatasource; - try - { - m_xDatabaseContext->getByName(_rDataSourceName) >>= xDatasource; - } - catch(Exception&) - { - } - return connect(xDatasource,_bShowError); + Reference< XDataSource > xDatasource( + getDataSourceByName_displayError( m_xDatabaseContext, _rDataSourceName, m_pErrorMessageParent, m_xORB, _bShowError ), + UNO_QUERY + ); + if ( xDatasource.is() ) + xConnection = connect( xDatasource, _bShowError ); + return xConnection; } + //--------------------------------------------------------------------- Reference< XConnection > ODatasourceConnector::connect(const Reference< XDataSource>& _xDataSource, sal_Bool _bShowError) const { --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
