summaryrefslogtreecommitdiff
path: root/xmloff
diff options
context:
space:
mode:
authorIngrid Halama <iha@openoffice.org>2010-06-04 18:22:13 +0200
committerIngrid Halama <iha@openoffice.org>2010-06-04 18:22:13 +0200
commit11eab80d847a072e49f6e13b022bb0d4a7cadd51 (patch)
tree1b892248daa28b065c6a6e07790170b333411a78 /xmloff
parentf8e7afbac976ca862a801b9648fd95b2107757b2 (diff)
calc55: #i112035# loading some old chart document fails
Diffstat (limited to 'xmloff')
-rw-r--r--xmloff/source/chart/SchXMLPlotAreaContext.cxx15
1 files changed, 10 insertions, 5 deletions
diff --git a/xmloff/source/chart/SchXMLPlotAreaContext.cxx b/xmloff/source/chart/SchXMLPlotAreaContext.cxx
index ec5c4b2130c1..cea7bf40b299 100644
--- a/xmloff/source/chart/SchXMLPlotAreaContext.cxx
+++ b/xmloff/source/chart/SchXMLPlotAreaContext.cxx
@@ -1249,18 +1249,23 @@ void SchXMLAxisContext::CreateAxis()
case SCH_XML_AXIS_Z:
{
+ bool bSettingZAxisSuccedded = false;
try
{
- xDiaProp->setPropertyValue(
- rtl::OUString::createFromAscii( "HasZAxis" ), aTrueBool );
+ rtl::OUString sHasZAxis( rtl::OUString::createFromAscii( "HasZAxis" ) );
+ xDiaProp->setPropertyValue( sHasZAxis, aTrueBool );
+ xDiaProp->getPropertyValue( sHasZAxis ) >>= bSettingZAxisSuccedded;
}
catch( beans::UnknownPropertyException & )
{
DBG_ERROR( "Couldn't turn on z axis" );
}
- uno::Reference< chart::XAxisZSupplier > xSuppl( mxDiagram, uno::UNO_QUERY );
- if( xSuppl.is())
- xProp = xSuppl->getZAxis();
+ if( bSettingZAxisSuccedded )
+ {
+ uno::Reference< chart::XAxisZSupplier > xSuppl( mxDiagram, uno::UNO_QUERY );
+ if( xSuppl.is())
+ xProp = xSuppl->getZAxis();
+ }
}
break;
case SCH_XML_AXIS_UNDEF: