close

My requirement is to use 3 types of output format with 10 possible cell
(input) values.

Example of the problem -

If cell value = quot;Aquot; OR quot;Bquot; OR quot;Cquot;, backcolor = Red
If cell value = quot;Dquot; OR quot;Equot; OR quot;Fquot; OR quot;Gquot; OR quot;Hquot; OR quot;Iquot;, backcolor = Green
If cell value = quot;Jquot; OR quot;quot;, backcolor = Yellow

I am aware of that VB programming can be done for this.
But I was thinking, if logical operators (e.g., AND, OR) can be used within
a conditional formatting, this problem can be solved very easily. (I tried by
myself, but could work it out.)

If anybody is aware of this, please let me know.Change the drop-down from quot;Cell value isquot; to quot;Formula isquot;, and
enter a formula like

=OR(A1=quot;Aquot;,A1=quot;Bquot;,A1=quot;Cquot;)

and similarly for the other two conditions.
Rumpa Biswas wrote:
gt; My requirement is to use 3 types of output format with 10 possible cell
gt; (input) values.
gt;
gt; Example of the problem -
gt;
gt; If cell value = quot;Aquot; OR quot;Bquot; OR quot;Cquot;, backcolor = Red
gt; If cell value = quot;Dquot; OR quot;Equot; OR quot;Fquot; OR quot;Gquot; OR quot;Hquot; OR quot;Iquot;, backcolor = Green
gt; If cell value = quot;Jquot; OR quot;quot;, backcolor = Yellow
gt;
gt; I am aware of that VB programming can be done for this.
gt; But I was thinking, if logical operators (e.g., AND, OR) can be used within
gt; a conditional formatting, this problem can be solved very easily. (I tried by
gt; myself, but could work it out.)
gt;
gt; If anybody is aware of this, please let me know.Hi Rumpa,
1. select A1 then Formatgt;Conditional format....
2. In the Formula Is box type =OR(A1=quot;Aquot;, A1=quot;Bquot;, A1=quot;Cquot;) then set the
red fill format
3.Click Addgt;gt; to goto the second condition
4.In the Formula Is box type =OR(A1=quot;Dquot;, A1=quot;Equot;, A1=quot;Fquot;, A1=quot;Gquot;,
A1=quot;Hquot;, A1=quot;Iquot;) then set the green fill format.
5.Click Addgt;gt; to go to the third condition
6.In the Formula Is box type =OR(A1=quot;Jquot;, A1=quot;quot;, A1=quot;Fquot;) then set the
yellow fill format.
7. Click OK then copy the format to cells you want affected.

Ken JohnsonHi Rumpa,
I'm trying again because nothing seemed to happen last time. If my
previous reply does appear I apologise for appearing repetitive.1. Select A1 then Formatgt;Conditional format....
2. In the Formula Is box type =OR(A1=quot;Aquot;, A1=quot;Bquot;, A1=quot;Cquot;) then set the
red fill format
3. Click Addgt;gt; to goto the second condition
4. In the Formula Is box type =OR(A1=quot;Dquot;, A1=quot;Equot;, A1=quot;Fquot;, A1=quot;Gquot;,
A1=quot;Hquot;, A1=quot;Iquot;) then set the green fill format.
5. Click Addgt;gt; to go to the third condition
6. In the Formula Is box type =OR(A1=quot;Jquot;, A1=quot;quot;, A1=quot;Fquot;) then set the
yellow fill format.
7.Click OK then copy the format to cells you want affected.

Ken JohnsonHi

In the Conditional Formatting dialogue, choose Formula is then set first
condition
=A1lt;quot;Dquot; and set format to Red
Add
=A1lt;quot;Jquot; and set format to Green
add
=A1gt;=quot;Jquot; and set format to Yellow

Change cell reference from A1 to whatever is appropriate

--
Regards

Roger Govier
Rumpa Biswas gt; wrote:
gt; My requirement is to use 3 types of output format with 10 possible
gt; cell (input) values.
gt;
gt; Example of the problem -
gt;
gt; If cell value = quot;Aquot; OR quot;Bquot; OR quot;Cquot;, backcolor = Red
gt; If cell value = quot;Dquot; OR quot;Equot; OR quot;Fquot; OR quot;Gquot; OR quot;Hquot; OR quot;Iquot;, backcolor =
gt; Green
gt; If cell value = quot;Jquot; OR quot;quot;, backcolor = Yellow
gt;
gt; I am aware of that VB programming can be done for this.
gt; But I was thinking, if logical operators (e.g., AND, OR) can be used
gt; within a conditional formatting, this problem can be solved very
gt; easily. (I tried by myself, but could work it out.)
gt;
gt; If anybody is aware of this, please let me know.
Hi Rumpa,
Ignore that ,A1=quot;Fquot; in step 6.
Ken JohnsonWith formula is, it worked fine. Thanks to everybody.

- Rumpa

quot;Rumpa Biswasquot; wrote:

gt; My requirement is to use 3 types of output format with 10 possible cell
gt; (input) values.
gt;
gt; Example of the problem -
gt;
gt; If cell value = quot;Aquot; OR quot;Bquot; OR quot;Cquot;, backcolor = Red
gt; If cell value = quot;Dquot; OR quot;Equot; OR quot;Fquot; OR quot;Gquot; OR quot;Hquot; OR quot;Iquot;, backcolor = Green
gt; If cell value = quot;Jquot; OR quot;quot;, backcolor = Yellow
gt;
gt; I am aware of that VB programming can be done for this.
gt; But I was thinking, if logical operators (e.g., AND, OR) can be used within
gt; a conditional formatting, this problem can be solved very easily. (I tried by
gt; myself, but could work it out.)
gt;
gt; If anybody is aware of this, please let me know.
gt;

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 software 的頭像
    software

    software

    software 發表在 痞客邦 留言(0) 人氣()