Issue 58572 - No native support for TRUE/FALSE primitives in calc.
Summary: No native support for TRUE/FALSE primitives in calc.
Status: CONFIRMED
Alias: None
Product: Calc
Classification: Application
Component: code (show other issues)
Version: OOO 2.0 Beta2
Hardware: All All
: P3 Trivial with 2 votes (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
: 84266 119698 (view as issue list)
Depends on:
Blocks:
 
Reported: 2005-11-28 15:33 UTC by noel.power
Modified: 2017-05-20 10:44 UTC (History)
5 users (show)

See Also:
Issue Type: ENHANCEMENT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description noel.power 2005-11-28 15:33:06 UTC
It would be most useful to be able to have the ability to distinguish between a
number and a boolean for a cell values in calc. Currently the only boolean
support is in the form of the TRUE() & FALSE() functions. This presents a number
of limitations 
* When these functions are evaluated from the api there doesn't seem to be a way
to distinguish between 0/1 and true/false as only a number can be retrieved (
table::CellContentType only distinguishes between number, string & function :-( ). 
* Granted in the code it is possible to distinguish between a number and a
boolean via the cell format attributes. This really isn't strong enough... for
example if you paste-special ( values only, a common operation ) a cell with a
boolean value the formating is lost. 
* Interfacing with oobasic ( user defined functions ) is also a pain as calc
boolean and basic's built-in boolean type evaluate differently ( oobasic
true/false value is determined by an expression that evaluates -1, 0
respectively, calc uses 0/1 symantics ) and you can't for example test the
boolean value of a cell directly. When you consider that its possible to link
form controls ( e.g. checkboxes, optionbuttons )to cells which modify those
cells values as a boolean and then want to drive code using those controls its
obvious that the situation is far from ideal. 
* From an interoperability point of view this also presents difficulties as
Excel has a built in boolean primitve which acts the same as oobasics boolean
primitive.

Thoughts?
Comment 1 frank 2006-02-17 14:41:01 UTC
Hi Niklas,

please comment on this one and proceed as needed.

Frank
Comment 2 Regina Henschel 2012-06-04 14:53:59 UTC
*** Issue 84266 has been marked as a duplicate of this issue. ***
Comment 3 Regina Henschel 2012-06-04 14:55:48 UTC
*** Issue 119698 has been marked as a duplicate of this issue. ***
Comment 4 Terry 2012-06-05 05:56:46 UTC
I am using OO 3.3 (Linux rpm version).  I was unaware of this defect.  I just experimented copying and paste special of a formula which returns 'false'.

If I paste all except formulas, 'FALSE' becomes 0.  If I omit formats, I also get zero.  If I omit numbers, I am left with an empty cell.

If I use the Basic code "oSelect.setDataArray( oSelect.getDataArray)," I get a zero.  If I use the dispatcher (in code) to paste all except formulas I also get a zero.
Comment 5 Marcus 2017-05-20 10:44:56 UTC
Reset the assignee to the default "issues@openoffice.apache.org".