diff options
author | Jianyuan Li <lijiany@apache.org> | 2012-09-25 04:53:47 +0000 |
---|---|---|
committer | Xisco Fauli <anistenis@gmail.com> | 2013-03-27 01:15:03 +0100 |
commit | 2d3f9fb97857fd8cfc732d3f5aa8f20b01e1cb35 (patch) | |
tree | 8627f7907345da4b10974e63adff27d519a96039 /sc | |
parent | 79a6b5191961c5dcc91f6e0b0b63f2e61a933823 (diff) |
Fix #119514#:Item lists are incorrectly imported
Reported by: Terry Yang
Reviewed by: sunying
Patched by: Jianyuan Li
Conflicts:
sc/source/filter/excel/xlpivot.cxx
Change-Id: I1e1c69004ed0764442298ae52c3bea87e6096bcd
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/filter/excel/xlpivot.cxx | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/sc/source/filter/excel/xlpivot.cxx b/sc/source/filter/excel/xlpivot.cxx index 84a6042afaa1..8a902e09279c 100644 --- a/sc/source/filter/excel/xlpivot.cxx +++ b/sc/source/filter/excel/xlpivot.cxx @@ -86,9 +86,19 @@ void XclPCItem::SetInteger( sal_Int16 nValue ) void XclPCItem::SetError( sal_uInt16 nError ) { meType = EXC_PCITEM_ERROR; - //! TODO convert error to string maText = rtl::OUString(); mnError = nError; + switch( nError ) + { + case 0x00: maText = "#NULL!"; break; + case 0x07: maText = "#DIV/0!"; break; + case 0x0F: maText = "#VALUE!"; break; + case 0x17: maText = "#REF!"; break; + case 0x1D: maText = "#NAME?"; break; + case 0x24: maText = "#NUM!"; break; + case 0x2A: maText = "#N/A"; break; + default: break; + } } void XclPCItem::SetBool( bool bValue ) @@ -125,7 +135,7 @@ bool XclPCItem::IsEmpty() const const rtl::OUString* XclPCItem::GetText() const { - return (meType == EXC_PCITEM_TEXT) ? &maText : 0; + return (meType == EXC_PCITEM_TEXT || meType == EXC_PCITEM_ERROR) ? &maText : NULL; } const double* XclPCItem::GetDouble() const |