Bug 150904 - Suggestion: Add a "Is empty" option for conditional formatting
Summary: Suggestion: Add a "Is empty" option for conditional formatting
Status: RESOLVED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.3.4.2 release
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-09-11 06:03 UTC by Kurosh Tavassoli
Modified: 2022-09-17 13:57 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kurosh Tavassoli 2022-09-11 06:03:36 UTC
Description:
When I want add a condition to a cell when its empty, I add the following condition:

IF &Cell is equal to "" THEN [condition]

a better way would be:

IF &Cell is empty THEN 

Steps to Reproduce:
Format -> Condition

Actual Results:
-

Expected Results:
-


Reproducible: Always


User Profile Reset: No



Additional Info:
-
Comment 1 Mike Kaganski 2022-09-11 06:20:10 UTC
(In reply to Kurosh Tavassoli from comment #0)
> When I want add a condition to a cell when its empty, I add the following
> condition:
> 
> IF &Cell is equal to "" THEN [condition]

Not exactly. It is not "&Cell", but "Cell value" - and that is really important. Empty cell does *not* have a value at all, so you can't check what its value is.

Instead, use "Formula is", and use ISEMPTY(cell), which expresses the intention explicitly.

IMO, it has no reason to try to add another option to the drop-down for every thinkable condition (which is impossible). The existence of formula condition gives user everything required to construct any condition they need.
Comment 2 Kurosh Tavassoli 2022-09-11 19:18:15 UTC
(In reply to Mike Kaganski from comment #1)
> (In reply to Kurosh Tavassoli from comment #0)
> > When I want add a condition to a cell when its empty, I add the following
> > condition:
> > 
> > IF &Cell is equal to "" THEN [condition]
> 
> Not exactly. It is not "&Cell", but "Cell value" - and that is really
> important. Empty cell does *not* have a value at all, so you can't check
> what its value is.
> 
> Instead, use "Formula is", and use ISEMPTY(cell), which expresses the
> intention explicitly.
> 
> IMO, it has no reason to try to add another option to the drop-down for
> every thinkable condition (which is impossible). The existence of formula
> condition gives user everything required to construct any condition they
> need.

Yes, I totally agree. Thanks
Comment 3 Kurosh Tavassoli 2022-09-11 19:57:57 UTC
(In reply to Kurosh Tavassoli from comment #2)
> (In reply to Mike Kaganski from comment #1)
> > (In reply to Kurosh Tavassoli from comment #0)
> > > When I want add a condition to a cell when its empty, I add the following
> > > condition:
> > > 
> > > IF &Cell is equal to "" THEN [condition]
> > 
> > Not exactly. It is not "&Cell", but "Cell value" - and that is really
> > important. Empty cell does *not* have a value at all, so you can't check
> > what its value is.
> > 
> > Instead, use "Formula is", and use ISEMPTY(cell), which expresses the
> > intention explicitly.
> > 
> > IMO, it has no reason to try to add another option to the drop-down for
> > every thinkable condition (which is impossible). The existence of formula
> > condition gives user everything required to construct any condition they
> > need.
> 
> Yes, I totally agree. Thanks

Excuse me, after thinking for a while I'm still confused. I want to color empty cells(In reply to Kurosh Tavassoli from comment #2)
> (In reply to Mike Kaganski from comment #1)
> > (In reply to Kurosh Tavassoli from comment #0)
> > > When I want add a condition to a cell when its empty, I add the following
> > > condition:
> > > 
> > > IF &Cell is equal to "" THEN [condition]
> > 
> > Not exactly. It is not "&Cell", but "Cell value" - and that is really
> > important. Empty cell does *not* have a value at all, so you can't check
> > what its value is.
> > 
> > Instead, use "Formula is", and use ISEMPTY(cell), which expresses the
> > intention explicitly.
> > 
> > IMO, it has no reason to try to add another option to the drop-down for
> > every thinkable condition (which is impossible). The existence of formula
> > condition gives user everything required to construct any condition they
> > need.
> 
> Yes, I totally agree. Thanks

Excuse me, I can't figure a way out for doing so. I want to add a condition to color all empty cells in my sheet. This is the best idea that crossed my mind:

FORMULA IS: ISBLANK(CELL("ADDRESS"))
Comment 4 Mike Kaganski 2022-09-11 21:07:53 UTC
When you create a condition, use relative address of the top left cell in your range. So if you selected B10:C150, the formula would be ISBLANK(B10).