dba33e: #i108128# catch exception when asking for driver

This commit is contained in:
Ocke Janssen [oj] 2010-02-18 11:33:14 +01:00
parent 66a73b89df
commit d8015eeea7

View file

@ -945,8 +945,15 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
{
::rtl::OUString sEmbeddedURL = m_pCollection->getEmbeddedDatabase();
::connectivity::DriversConfig aDriverConfig(getORB());
try
{
if ( !aDriverConfig.getDriverFactoryName(sEmbeddedURL).getLength() || !m_pImpl->getDriver(sEmbeddedURL).is() )
sEmbeddedURL = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sdbc:dbase:"));
}
catch(const Exception&)
{
sEmbeddedURL = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sdbc:dbase:"));
}
return sEmbeddedURL;
}