diff options
author | Thomas Arnhold <thomas@arnhold.org> | 2013-10-07 12:02:33 +0200 |
---|---|---|
committer | Thomas Arnhold <thomas@arnhold.org> | 2013-10-07 12:02:33 +0200 |
commit | 6349540d939e3bc3a96cec2615352a4b056b7fa5 (patch) | |
tree | 72396f86f125c279d4c5504d41e1ee1410e6c7eb /sc | |
parent | 618ade76fddc3feae37970a0ac9e366244cc3216 (diff) |
really fix it
arg. sorry...
Change-Id: I57836c574f4f622296c38d7a0adb6adcbb768aa2
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/filter/html/htmlexp.cxx | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/sc/source/filter/html/htmlexp.cxx b/sc/source/filter/html/htmlexp.cxx index 0c93bccf2f4a..6217cd514ed8 100644 --- a/sc/source/filter/html/htmlexp.cxx +++ b/sc/source/filter/html/htmlexp.cxx @@ -1039,6 +1039,27 @@ void ScHTMLExport::WriteCell( SCCOL nCol, SCROW nRow, SCTAB nTab ) aStrTD.append(lcl_makeHTMLColorTriplet(aBgColor)); } + double fVal = 0.0; + if ( bValueData ) + { + switch (aCell.meType) + { + case CELLTYPE_VALUE: + fVal = aCell.mfValue; + if ( bCalcAsShown && fVal != 0.0 ) + fVal = pDoc->RoundValueAsShown( fVal, nFormat ); + break; + case CELLTYPE_FORMULA: + fVal = aCell.mpFormula->GetValue(); + break; + default: + OSL_FAIL( "value data with unsupported cell type" ); + } + } + + aStrTD.append(HTMLOutFuncs::CreateTableDataOptionsValNum(bValueData, fVal, + nFormat, *pFormatter, eDestEnc, &aNonConvertibleChars)); + TAG_ON(aStrTD.makeStringAndClear().getStr()); if ( bBold ) TAG_ON( OOO_STRING_SVTOOLS_HTML_bold ); |