Bug 83779

Summary: FILESAVE: Error in saving as Excel files - logical boolean type of FALSE and TRUE values not preserved during input
Product: LibreOffice Reporter: Marius Marsh <spiritofmar98>
Component: SpreadsheetAssignee: Not Assigned <libreoffice-bugs>
Status: NEW --- QA Contact:
Severity: normal    
Priority: medium    
Version: Inherited From OOo   
Hardware: All   
OS: All   
Whiteboard: BSA
i915 platform: i915 features:

Description Marius Marsh 2014-09-11 18:59:44 UTC
Problem description: 

Steps to reproduce:
1. Create a file with a functioning algorithm that includes IF(ISNUMBER(XX)=0  ( I note that LO calc will convert the word "FALSE" to 0 whether you type it in or it comes from an Excel file)
2.Save the file as an Excel file (.xls, .xlsx etc) 
3.Open the file in Excel (I tried it in Excel 2010, and 2007) 

Current behavior:
LO calc doesn't convert the 0 in IF(ISNUMBER(XX)=0 to "FALSE", and then Excel sees the 0 in IF(ISNUMBER(XX)=0 as the number 0.  All subsequent dependent algorithms are then in error (if cell (xx) isn't the number 0. 

Expected behavior:
 LO calc should convert the 0 to "FALSE".  Similarly, if the algoritm were IF(ISNUMBER(XX)=1, it should convert the 1 to "TRUE" (but, I am not sure why one would ever need to do the latter) 

              
Operating System: Windows 7
Version: 4.2.5.2 release
Comment 1 Eike Rathke 2014-09-11 21:39:58 UTC
Calc does not have a distinct boolean type, whereas Excel does and expects it and does not convert numeric type to boolean type. The expression IF(ISNUMBER(XX)=FALSE,...) or IF(ISNUMBER(XX)=0,...) can be rewritten as IF(ISNUMBER(XX)=FALSE(),...) or IF(NOT(ISNUMBER(XX)),...) so that both applications understand it.

It may be desirable to preserve input and imported FALSE and TRUE values by converting them to FALSE() and TRUE() functions.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.