diff options
Diffstat (limited to 'sc/source/core/data/dpoutput.cxx')
-rw-r--r-- | sc/source/core/data/dpoutput.cxx | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/sc/source/core/data/dpoutput.cxx b/sc/source/core/data/dpoutput.cxx index 7ecdc3d34702..401d9b396bc0 100644 --- a/sc/source/core/data/dpoutput.cxx +++ b/sc/source/core/data/dpoutput.cxx @@ -451,14 +451,12 @@ ScDPOutput::ScDPOutput( ScDocument* pD, const uno::Reference<sheet::XDimensionsS if ( xLevNam.is() && xLevRes.is() ) { String aName = xLevNam->getName(); - OUString aCaption = aName; // Caption equals the field name by default. Reference<XPropertySet> xPropSet(xLevel, UNO_QUERY); - if (xPropSet.is()) - { - Any any = xPropSet->getPropertyValue( - OUString::createFromAscii(SC_UNO_LAYOUTNAME)); - any >>= aCaption; - } + // Caption equals the field name by default. + // #i108948# use ScUnoHelpFunctions::GetStringProperty, because + // LayoutName is new and may not be present in external implementation + OUString aCaption = ScUnoHelpFunctions::GetStringProperty( xPropSet, + OUString::createFromAscii(SC_UNO_LAYOUTNAME), aName ); bool bRowFieldHasMember = false; switch ( eDimOrient ) |