Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 52
Default Multiple IF statment help

Evening everyone

I am sure this is simple but it's late and I'm very tired.

I have the following IF statment but I need all three to be added together -
the sum of D147,F147 & H147

=IF($C147<J$3,$D147,"")+IF($E147<J$3,$F147,"")+IF( $G147<J$3,$H147,"")

All I am getting is a VALUE come up.

Thanks
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,501
Default Multiple IF statment help

Hi,

You were very close, try this

=IF($C147<J$3,$D147,0)+IF($E147<J$3,$F147,0)+IF($G 147<J$3,$H147,0)
--
Mike

When competing hypotheses are otherwise equal, adopt the hypothesis that
introduces the fewest assumptions while still sufficiently answering the
question.


"Mark D" wrote:

Evening everyone

I am sure this is simple but it's late and I'm very tired.

I have the following IF statment but I need all three to be added together -
the sum of D147,F147 & H147

=IF($C147<J$3,$D147,"")+IF($E147<J$3,$F147,"")+IF( $G147<J$3,$H147,"")

All I am getting is a VALUE come up.

Thanks

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 52
Default Multiple IF statment help

Hi Mike

Yep that works, although I just found why it's taken so long for me to work
out

In the formula you have helped me with

=IF($C147<J$3,$D147,0)+IF($E147<J$3,$F147,0)+IF($G 147<J$3,$H147,0)

D147, F147 & H147 sometimes have no value in them and are blank, the
following forumula exists in those cells

=IF(ISBLANK($H104),"",$H104)

If I remove this formula then of course your formula works. But I need te
formula in cells d147 ETC to stay

Thanks again for your help

"Mike H" wrote:

Hi,

You were very close, try this

=IF($C147<J$3,$D147,0)+IF($E147<J$3,$F147,0)+IF($G 147<J$3,$H147,0)
--
Mike

When competing hypotheses are otherwise equal, adopt the hypothesis that
introduces the fewest assumptions while still sufficiently answering the
question.


"Mark D" wrote:

Evening everyone

I am sure this is simple but it's late and I'm very tired.

I have the following IF statment but I need all three to be added together -
the sum of D147,F147 & H147

=IF($C147<J$3,$D147,"")+IF($E147<J$3,$F147,"")+IF( $G147<J$3,$H147,"")

All I am getting is a VALUE come up.

Thanks

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 905
Default Multiple IF statment help

"Mark D" wrote:
In the formula you have helped me with
=IF($C147<J$3,$D147,0)+
IF($E147<J$3,$F147,0)+
IF($G147<J$3,$H147,0)

D147, F147 & H147 sometimes have no value
in them and are blank, the following forumula
exists in those cells
=IF(ISBLANK($H104),"",$H104)


So they do have a value, namely the null string. They only appear to be
blank.

Try:

=($C147<J$3)*N($D147)+
($E147<J$3)*N($F147)+($G147<J$3)*N($H147)

But what about C147, E147, G147 and J3. Are those numeric? If so, could
those also contain the null string value ("")?

If yes, note that even though you do not get an Excel error like #VALUE, the
formulas might still be wrong because in a comparison between text ("") and
number, text is always considered larger(!).

So you might want:

=(N($C147)<N(J$3))*N($D147)+
(N($E147)<N(J$3))*N($F147)+
(N($G147)<N(J$3))*N($H147)


----- original message -----

"Mark D" wrote:
Hi Mike

Yep that works, although I just found why it's taken so long for me to work
out

In the formula you have helped me with

=IF($C147<J$3,$D147,0)+IF($E147<J$3,$F147,0)+IF($G 147<J$3,$H147,0)

D147, F147 & H147 sometimes have no value in them and are blank, the
following forumula exists in those cells

=IF(ISBLANK($H104),"",$H104)

If I remove this formula then of course your formula works. But I need te
formula in cells d147 ETC to stay

Thanks again for your help

"Mike H" wrote:

Hi,

You were very close, try this

=IF($C147<J$3,$D147,0)+IF($E147<J$3,$F147,0)+IF($G 147<J$3,$H147,0)
--
Mike

When competing hypotheses are otherwise equal, adopt the hypothesis that
introduces the fewest assumptions while still sufficiently answering the
question.


"Mark D" wrote:

Evening everyone

I am sure this is simple but it's late and I'm very tired.

I have the following IF statment but I need all three to be added together -
the sum of D147,F147 & H147

=IF($C147<J$3,$D147,"")+IF($E147<J$3,$F147,"")+IF( $G147<J$3,$H147,"")

All I am getting is a VALUE come up.

Thanks

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
Multiple IF Statment not working Mark D[_2_] Excel Worksheet Functions 4 November 20th 09 10:51 AM
Using COUNTIF for multiple text data creating a logic statment Scott Excel Worksheet Functions 12 January 16th 08 12:18 AM
multiple if statment maijiuli Excel Worksheet Functions 2 June 2nd 07 12:02 AM
IF Statment across Multiple Sheets jdeer0618 Excel Worksheet Functions 1 May 18th 06 11:20 AM
Multiple IF THEN ELSE statment Mark G Excel Worksheet Functions 5 March 18th 05 08:51 PM


All times are GMT +1. The time now is 07:22 AM.

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"