Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 28
Default Formatting "IF" response based on "OR" function

I have an IF statement based on 2 criteria in an OR statement.

.....IF a1=a2 or a1=a3, show a1 contents in a4....for instance.

I want to format a2 automatically depending on which of the 2 statements
about a1 turn out to be TRUE.

If a1=a2, show contents in a4 and make it bold text...if a1=a3, show
contents in a4, and make it italic text....for instance.

The problem is I can't use conditional formatting for the specific cells,
because the value in a4 is going to change depending on what I type in a2 and
a3.

Can anyone help?
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,058
Default Formatting "IF" response based on "OR" function

In A4 enter:

=IF(OR(A1=A2,A1=A3),A1,"")

Then select A4 and enter two conditional formats:

1. Formula Is =A1=A2 and pick Bold
2. Formula Is =A1=A3 and pick Italic
--
Gary''s Student - gsnu200774


"veggies27" wrote:

I have an IF statement based on 2 criteria in an OR statement.

....IF a1=a2 or a1=a3, show a1 contents in a4....for instance.

I want to format a2 automatically depending on which of the 2 statements
about a1 turn out to be TRUE.

If a1=a2, show contents in a4 and make it bold text...if a1=a3, show
contents in a4, and make it italic text....for instance.

The problem is I can't use conditional formatting for the specific cells,
because the value in a4 is going to change depending on what I type in a2 and
a3.

Can anyone help?

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 28
Default Formatting "IF" response based on "OR" function

What about if I am drawing from another worksheet? A2 and A3 in the cases
below are in another worksheet. Conditional fomrating wont let me use a
formula containing abnother worksheet.

"Gary''s Student" wrote:

In A4 enter:

=IF(OR(A1=A2,A1=A3),A1,"")

Then select A4 and enter two conditional formats:

1. Formula Is =A1=A2 and pick Bold
2. Formula Is =A1=A3 and pick Italic
--
Gary''s Student - gsnu200774


"veggies27" wrote:

I have an IF statement based on 2 criteria in an OR statement.

....IF a1=a2 or a1=a3, show a1 contents in a4....for instance.

I want to format a2 automatically depending on which of the 2 statements
about a1 turn out to be TRUE.

If a1=a2, show contents in a4 and make it bold text...if a1=a3, show
contents in a4, and make it italic text....for instance.

The problem is I can't use conditional formatting for the specific cells,
because the value in a4 is going to change depending on what I type in a2 and
a3.

Can anyone help?

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,058
Default Formatting "IF" response based on "OR" function

Cheat and use a local cell. For example, if we want to test if A1 is equal
to A1 on Sheet2, then do not use:
=A1=Sheet2!A1
use:
=A1=B1
and set B1 up as =Sheet2!a1


REMEMBER. cells are cheap, your time is valuable...use the extra cell!
--
Gary''s Student - gsnu200774


"veggies27" wrote:

What about if I am drawing from another worksheet? A2 and A3 in the cases
below are in another worksheet. Conditional fomrating wont let me use a
formula containing abnother worksheet.

"Gary''s Student" wrote:

In A4 enter:

=IF(OR(A1=A2,A1=A3),A1,"")

Then select A4 and enter two conditional formats:

1. Formula Is =A1=A2 and pick Bold
2. Formula Is =A1=A3 and pick Italic
--
Gary''s Student - gsnu200774


"veggies27" wrote:

I have an IF statement based on 2 criteria in an OR statement.

....IF a1=a2 or a1=a3, show a1 contents in a4....for instance.

I want to format a2 automatically depending on which of the 2 statements
about a1 turn out to be TRUE.

If a1=a2, show contents in a4 and make it bold text...if a1=a3, show
contents in a4, and make it italic text....for instance.

The problem is I can't use conditional formatting for the specific cells,
because the value in a4 is going to change depending on what I type in a2 and
a3.

Can anyone help?



  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 22,906
Default Formatting "IF" response based on "OR" function

You can use a range or cell from another worksheet if you name that range or
cell.


Gord Dibben MS Excel MVP

On Wed, 19 Mar 2008 08:04:05 -0700, veggies27
wrote:

What about if I am drawing from another worksheet? A2 and A3 in the cases
below are in another worksheet. Conditional fomrating wont let me use a
formula containing abnother worksheet.

"Gary''s Student" wrote:

In A4 enter:

=IF(OR(A1=A2,A1=A3),A1,"")

Then select A4 and enter two conditional formats:

1. Formula Is =A1=A2 and pick Bold
2. Formula Is =A1=A3 and pick Italic
--
Gary''s Student - gsnu200774


"veggies27" wrote:

I have an IF statement based on 2 criteria in an OR statement.

....IF a1=a2 or a1=a3, show a1 contents in a4....for instance.

I want to format a2 automatically depending on which of the 2 statements
about a1 turn out to be TRUE.

If a1=a2, show contents in a4 and make it bold text...if a1=a3, show
contents in a4, and make it italic text....for instance.

The problem is I can't use conditional formatting for the specific cells,
because the value in a4 is going to change depending on what I type in a2 and
a3.

Can anyone help?


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Text "comparison" operator for "contains" used in an "IF" Function Pawaso Excel Worksheet Functions 4 April 4th 23 11:35 AM
change "true" and "false" to "availble" and "out of stock" inthestands Excel Worksheet Functions 2 July 19th 07 07:05 PM
Macro to concatenate into "B1" B2 thru B"x" based on new data in "Col A" Dennis Excel Discussion (Misc queries) 0 July 17th 06 02:38 PM
HELP on "left","right","find","len","substitute" functions serene83 Excel Discussion (Misc queries) 5 June 27th 06 02:23 AM
Count occurences of "1"/"0" (or"TRUE"/"FALSE") in a row w. conditions in the next BCB New Users to Excel 7 May 13th 06 10:02 PM


All times are GMT +1. The time now is 01:52 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"