[Solved] How to populate a cell with text dependant on contents of another cell?

Discuss the spreadsheet application
Post Reply
Bones541
Posts: 7
Joined: Sun Sep 25, 2022 6:23 am

[Solved] How to populate a cell with text dependant on contents of another cell?

Post by Bones541 »

Im trying to look for a formula that will populate a cell with a word depending on the contents of another cell.

The deciding cell could be based from a negative or positive number, a populated or empty cell, or a certain word in that cell.

Ive been using a formula to populate another cell dependant on if the deciding cell is positive or negative, and am wondering if that formula could be adapted.

Ive been using =IF(E2<0;E2;"")
And =IF(E2>0;E2;"")

But as i wrote i have a few options on which cell could be the deciding cell, so options are open on other possible formulas.

Any help greatly appreciated.

Figured it out.

=IF(E2<0;"Word")
Last edited by robleyd on Sun Sep 25, 2022 2:26 pm, edited 1 time in total.
Reason: Add green tick
OpenOffice 4.1.13 Windows 10
Bones541
Posts: 7
Joined: Sun Sep 25, 2022 6:23 am

How to pupulate a cell with text dependant on contents of another cell?

Post by Bones541 »

Im trying to look for a formula that will populate a cell with a word depending on the contents of another cell.

The deciding cell could be based from a negative or positive number, a populated or empty cell, or a certain word in that cell.

Ive been using a formula to populate another cell dependant on if the deciding cell is positive or negative, and am wondering if that formula could be adapted.

Ive been using =IF(E2<0;E2;"")
And =IF(E2>0;E2;"")

But as i wrote i have a few options on which cell could be the deciding cell, so options are open on other possible formulas.

Any help greatly appreciated.

Half figured it. If i use =IF(E2<0;"word")

But that puts false in that corresponding cell if its greater than 0, and id need that box empty.
OpenOffice 4.1.13 Windows 10
Bones541
Posts: 7
Joined: Sun Sep 25, 2022 6:23 am

How to pupulate a cell with text dependant on contents of another cell?

Post by Bones541 »

Im trying to look for a formula that will populate a cell with a word depending on the contents of another cell.

The deciding cell could be based from a negative or positive number, a populated or empty cell, or a certain word in that cell.

Ive been using a formula to populate another cell dependant on if the deciding cell is positive or negative, and am wondering if that formula could be adapted.

Ive been using =IF(E2<0;E2;"")
And =IF(E2>0;E2;"")

But as i wrote i have a few options on which cell could be the deciding cell, so options are open on other possible formulas.

Any help greatly appreciated.

Half figured it. If i use =IF(E2<0;"word")

But that puts false in that corresponding cell if its greater than 0, and id need that box empty.

A little futher ahead now with =IF(E2<0;"word":" ")
It inputs a space instead of the word false.

Is there a way to do it so the cell is completely empty?
Or so the word enters a different cell if >0 ?
OpenOffice 4.1.13 Windows 10
User avatar
robleyd
Moderator
Posts: 5056
Joined: Mon Aug 19, 2013 3:47 am
Location: Murbko, Australia

Re: [Solved] How to populate a cell with text dependant on contents of another cell?

Post by robleyd »

Is there a way to do it so the cell is completely empty?
Strictly speaking, no, because the cell contains a formula. But what I suspect you want is

Code: Select all

=IF(E2<0;"word";"")
Cheers
David
OS - Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 24.2.1.2; SlackBuild for 24.2.1 by Eric Hameleers
Bones541
Posts: 7
Joined: Sun Sep 25, 2022 6:23 am

Re: [Solved] How to populate a cell with text dependant on contents of another cell?

Post by Bones541 »

Thsnks, yes that is what i was looking for
OpenOffice 4.1.13 Windows 10
Post Reply