#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 390
Default Add to a formula

hello
I have this formula

=IF(L43=0,0,IF(L43=1,1,IF(OR(L43=7,L43=8),8,IF(L43 =9,13,IF(L43=5,5,IF(L43=2,2,IF(L43=6,6,)))))))
and I want to add that when L43=7.5 it comes an output of 7.5, any help.
Thanks in advance.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,231
Default Add to a formula

MAX wrote...
....
=IF(L43=0,0,IF(L43=1,1,IF(OR(L43=7,L43=8),8,IF(L4 3=9,13,IF(L43=5,5,IF(L43=2,2,IF(L43=6,6,)))))))
and I want to add that when L43=7.5 it comes an output of 7.5, any help.

....

So you want the formula to return 0 when L43 doesn't equal any of the
given values?

One way,

=IF(OR(L43={0;1;2;5;6;7;7.5;8;9}),
LOOKUP(L43,{0;1;2;5;6;7;7.5;8;9},{0;1;2;5;6;8;7.5; 8;13}),0)

It's generally best to use LOOKUP functions for this sort of thing.
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,389
Default Add to a formula

Try the following:
=if(l43=7,8,if(l43=9,13,l43))

Regards,
Fred.

"MAX" wrote in message
...
hello
I have this formula

=IF(L43=0,0,IF(L43=1,1,IF(OR(L43=7,L43=8),8,IF(L43 =9,13,IF(L43=5,5,IF(L43=2,2,IF(L43=6,6,)))))))
and I want to add that when L43=7.5 it comes an output of 7.5, any help.
Thanks in advance.


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 26
Default Add to a formula

Hi Max

IMHO Nested If's are restricted to 7 maximum

Creat a list and vlookup the values

=VLOOKUP(L43,F5:G13,2,FALSE)

Columns

F G

0 0

1 1

2 2

5 5

6 6

7 8

7.5 7.5

8 8

9 13

Best Regards

Rajesh Mehmi



"MAX" wrote in message
...
hello
I have this formula

=IF(L43=0,0,IF(L43=1,1,IF(OR(L43=7,L43=8),8,IF(L43 =9,13,IF(L43=5,5,IF(L43=2,2,IF(L43=6,6,)))))))
and I want to add that when L43=7.5 it comes an output of 7.5, any help.
Thanks in advance.



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



All times are GMT +1. The time now is 10:41 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"