diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2017-02-14 16:10:19 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2017-02-15 14:17:57 +0000 |
commit | 6113c68c7653f545f762b22f70adc518cf8d660d (patch) | |
tree | c1aa951c20c38f4e210bb815ac1a966e55243298 /sc/source/ui/vba/vbarange.cxx | |
parent | 9a22e9691773e7d16fbc8da1568e5d67d76fcf08 (diff) |
Some simplifications, using UNO_QUERY_THROW
Change-Id: If7a8abbf739aca98616ecb5cc3546ced192361d9
Reviewed-on: https://gerrit.libreoffice.org/34261
Tested-by: Stephan Bergmann <sbergman@redhat.com>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'sc/source/ui/vba/vbarange.cxx')
-rw-r--r-- | sc/source/ui/vba/vbarange.cxx | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/sc/source/ui/vba/vbarange.cxx b/sc/source/ui/vba/vbarange.cxx index 4d444f2aaebc..e11234142647 100644 --- a/sc/source/ui/vba/vbarange.cxx +++ b/sc/source/ui/vba/vbarange.cxx @@ -3174,9 +3174,7 @@ ScVbaRange::Find( const uno::Any& What, const uno::Any& After, const uno::Any& L // After must be a single cell in the range if( xAfterRange->getCount() > 1 ) throw uno::RuntimeException("After must be a single cell." ); - uno::Reference< excel::XRange > xCell( Cells( uno::makeAny( xAfterRange->getRow() ), uno::makeAny( xAfterRange->getColumn() ) ), uno::UNO_QUERY ); - if( !xCell.is() ) - throw uno::RuntimeException("After must be in range." ); + uno::Reference< excel::XRange > xCell( Cells( uno::makeAny( xAfterRange->getRow() ), uno::makeAny( xAfterRange->getColumn() ) ), uno::UNO_QUERY_THROW ); xStartCell.set( xAfterRange->getCellRange(), uno::UNO_QUERY_THROW ); } |