update ooo310-m15
[ooovba.git] / applied_patches / 0196-calc-dde-always-ooo-conv.diff
blobd1f75d5de28a706051f6d1537c3b5deab5ee5c89
1 diff --git sc/source/ui/docshell/docsh4.cxx sc/source/ui/docshell/docsh4.cxx
2 index 783c7f9..a9a5820 100644
3 --- sc/source/ui/docshell/docsh4.cxx
4 +++ sc/source/ui/docshell/docsh4.cxx
5 @@ -2473,10 +2473,14 @@ long __EXPORT ScDocShell::DdeSetData( const String& rItem,
6 pData->GetSymbol( aPos ); // continue with the name's contents
9 - ScRange aRange;
10 - formula::FormulaGrammar::AddressConvention eConv = aDocument.GetAddressConvention();
11 - BOOL bValid = ( ( aRange.Parse( aPos, &aDocument, eConv ) & SCA_VALID ) ||
12 - ( aRange.aStart.Parse( aPos, &aDocument, eConv ) & SCA_VALID ) );
14 + // Address in DDE function must be always parsed as CONV_OOO so that it
15 + // would always work regardless of current address convension. We do this
16 + // because the address item in a DDE entry is *not* normalized when saved
17 + // into ODF.
18 + ScRange aRange;
19 + bool bValid = ( (aRange.Parse(aPos, &aDocument, formula::FormulaGrammar::CONV_OOO ) & SCA_VALID) ||
20 + (aRange.aStart.Parse(aPos, &aDocument, formula::FormulaGrammar::CONV_OOO) & SCA_VALID) );
22 ScServerObject* pObj = NULL; // NULL = error
23 if ( bValid )