#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 24
Default nested if

I have the following if statement.
The third IF statement is not working.
Please help.
Thank you.
Arlene

=IF(D10<K10,L10,IF(D10=K10,F10,IF(D10=0,0.00)))
the 3rd IF statement can also be interpreted as IF(B10=' ',D10)))
If cell B10 is blank, then return the value in D10
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,358
Default nested if

Your first 2 IF statements, D10<K10 and D10=K10, well D10 will always meet
one of those 2 criteria, so will never worry about D10=0. You need to
evaluate that first:
=IF(D10=0,0,IF(D10<K10,L10,F10))

Hope this helps.
--
** John C **
Please remember if your question is answered, to mark it answered :). It
helps everyone.


"ACarella" wrote:

I have the following if statement.
The third IF statement is not working.
Please help.
Thank you.
Arlene

=IF(D10<K10,L10,IF(D10=K10,F10,IF(D10=0,0.00)))
the 3rd IF statement can also be interpreted as IF(B10=' ',D10)))
If cell B10 is blank, then return the value in D10

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,501
Default nested if

Maybe

=IF(D10="","",IF(D10<L10,L10,IF(D10=K10,F10)))

or

=IF(D10="",0,IF(D10<L10,L10,IF(D10=K10,F10)))

Miek

"ACarella" wrote:

I have the following if statement.
The third IF statement is not working.
Please help.
Thank you.
Arlene

=IF(D10<K10,L10,IF(D10=K10,F10,IF(D10=0,0.00)))
the 3rd IF statement can also be interpreted as IF(B10=' ',D10)))
If cell B10 is blank, then return the value in D10

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2,819
Default nested if

The first 2 IFs cover ALL possible situations. The 3rd IF is never going
to be used.

ACarella wrote:

I have the following if statement.
The third IF statement is not working.
Please help.
Thank you.
Arlene

=IF(D10<K10,L10,IF(D10=K10,F10,IF(D10=0,0.00)))
the 3rd IF statement can also be interpreted as IF(B10=' ',D10)))
If cell B10 is blank, then return the value in D10


  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,358
Default nested if

Or you could even do this:
=(D10=0)*((D10=0)*K10+(D10<0)*L10)
--
** John C **

"John C" wrote:

Your first 2 IF statements, D10<K10 and D10=K10, well D10 will always meet
one of those 2 criteria, so will never worry about D10=0. You need to
evaluate that first:
=IF(D10=0,0,IF(D10<K10,L10,F10))

Hope this helps.
--
** John C **
Please remember if your question is answered, to mark it answered :). It
helps everyone.


"ACarella" wrote:

I have the following if statement.
The third IF statement is not working.
Please help.
Thank you.
Arlene

=IF(D10<K10,L10,IF(D10=K10,F10,IF(D10=0,0.00)))
the 3rd IF statement can also be interpreted as IF(B10=' ',D10)))
If cell B10 is blank, then return the value in D10



  #6   Report Post  
Posted to microsoft.public.excel.misc
Max Max is offline
external usenet poster
 
Posts: 9,221
Default nested if

If cell B10 is blank, then return the value in D10

It should actually look like this: =IF(B10="",D10)

As for your main:
=IF(D10<K10,L10,IF(D10=K10,F10,IF(D10=0,0.00)))


Try this revision/re-sequenced:
=IF(D10="",0,IF(D10<K10,L10,F10))
which checks for D10 being blank/containing formula blanks
ahead of its subsequent comparison with values in other cell

--
Max
Singapore
http://savefile.com/projects/236895
Downloads:20,000 Files:362 Subscribers:62
xdemechanik
---
  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 24
Default nested if

Sorry it took me so long.
That did it Jon C.
Thank you very much.
Arlene

"John C" wrote:

Your first 2 IF statements, D10<K10 and D10=K10, well D10 will always meet
one of those 2 criteria, so will never worry about D10=0. You need to
evaluate that first:
=IF(D10=0,0,IF(D10<K10,L10,F10))

Hope this helps.
--
** John C **
Please remember if your question is answered, to mark it answered :). It
helps everyone.


"ACarella" wrote:

I have the following if statement.
The third IF statement is not working.
Please help.
Thank you.
Arlene

=IF(D10<K10,L10,IF(D10=K10,F10,IF(D10=0,0.00)))
the 3rd IF statement can also be interpreted as IF(B10=' ',D10)))
If cell B10 is blank, then return the value in D10

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
IF with nested AND Joco Excel Discussion (Misc queries) 12 July 15th 08 07:36 PM
nested ifs not enough Vincent Excel Discussion (Misc queries) 1 August 23rd 07 03:58 PM
nested if based on nested if in seperate sheet. how? scouserabbit Excel Worksheet Functions 5 March 2nd 07 04:03 PM
Nested If / And / Or ? Titian Excel Discussion (Misc queries) 4 November 22nd 05 11:16 AM
Nested IF Keith in Australia Excel Discussion (Misc queries) 3 August 22nd 05 04:44 AM


All times are GMT +1. The time now is 06:16 AM.

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

About Us

"It's about Microsoft Excel"