Home

Formula Help

%3CLINGO-SUB%20id%3D%22lingo-sub-821043%22%20slang%3D%22en-US%22%3EFormula%20Help%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-821043%22%20slang%3D%22en-US%22%3E%3CP%3EI%20need%20help%20with%20a%20formula.%26nbsp%3B%20I%20have%203%20cells%2C%20D20%2C%20D21%2C%20and%20D22%2C%20IF%20any%20of%20these%20three%20cells%20contains%20an%20%22X%22%2C%20then%20the%20cell%20with%20the%20formula%20displays%20%22X%22.%26nbsp%3B%20If%20none%20of%20the%20cells%20contain%20an%20%22X%22%2C%20then%20the%20formula%20cell%20is%20empty%3B%20%22%22.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%20in%20advance.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-821043%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EFormulas%20and%20Functions%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-821076%22%20slang%3D%22en-US%22%3ERe%3A%20Formula%20Help%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-821076%22%20slang%3D%22en-US%22%3ETry%20this%3A%3CBR%20%2F%3E%3DIF(COUNTIF(D20%3AD22%2C%3CBR%20%2F%3E%E2%80%9CX%E2%80%9D)%2C%E2%80%9DX%E2%80%9D%2C%E2%80%9D%E2%80%9D)%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-821169%22%20slang%3D%22en-US%22%3ERe%3A%20Formula%20Help%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-821169%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F397658%22%20target%3D%22_blank%22%3E%40David869197%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EOr%20if%20there%20is%20only%20X%20or%20empty%20possible.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-markup%22%3E%3CCODE%3E%3DIF(COUNTA(D20%3AD22)%2C%22X%22%2C%22%22)%3C%2FCODE%3E%3C%2FPRE%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EOr%20just%3A%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-markup%22%3E%3CCODE%3E%3DCOUNTA(D20%3AD22)%3C%2FCODE%3E%3C%2FPRE%3E%3CP%3Eand%20number%20format%20as%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-markup%22%3E%3CCODE%3E%22X%22%3B%3B%3B%3C%2FCODE%3E%3C%2FPRE%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
David869197
Occasional Visitor

I need help with a formula.  I have 3 cells, D20, D21, and D22, IF any of these three cells contains an "X", then the cell with the formula displays "X".  If none of the cells contain an "X", then the formula cell is empty; "".

 

Thanks in advance.

2 Replies
Highlighted
Try this:
=IF(COUNTIF(D20:D22,
“X”),”X”,””)

@David869197 

Or if there is only X or empty possible.

 

=IF(COUNTA(D20:D22),"X","")

 

Or just:

=COUNTA(D20:D22)

and number format as

"X";;;

 

Related Conversations
Tabs and Dark Mode
cjc2112 in Discussions on
16 Replies
flashing a white screen while open new tab
cntvertex in Discussions on
11 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
28 Replies
Early preview of Microsoft Edge group policies
Sean Lyndersay in Discussions on
65 Replies