ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Nested If/Then statements (https://www.excelbanter.com/excel-worksheet-functions/59587-nested-if-then-statements.html)

qwik6

Nested If/Then statements
 

Hello Everyone,
I sure could use a little help. I started with this If/Then statement
and it seems to get hung at what I understand to be the 1st "test".
I'm not sure what I'm doing wrong here......I'm loading this statement
for 8 different values (all under 500) and its supposed to bring back a
response for each value, but all it lists is the V. Any help would be
appreciated.

=IF(B4<=500,"V",IF(B4<=400,"W",IF(B4<=300,"X",IF(B 4<=200,"Y",IF(B4<=100,"Z","")))))


--
qwik6
------------------------------------------------------------------------
qwik6's Profile: http://www.excelforum.com/member.php...o&userid=29502
View this thread: http://www.excelforum.com/showthread...hreadid=492068


duane

Nested If/Then statements
 

it will return V for any value in b4 <= 500 - you need to invert it to
get what you want

=IF(B4<=500,"V",IF(B4<=400,"W",IF(B4<=300,"X",IF(B
4<=200,"Y",IF(B4<=100,"Z","")))))

=IF(B4<=100,"Z",IF(B4<=200,"Y",IF(B4<=300,"X",IF(B 4<=400,"W",IF(B4<=500,"V","")))))

will return for B$

Z <=100
Y 100<B4<=200
X 200<B4<=300
W 300<B4<=400
V 400<B4<=500
"" anything else


--
duane


------------------------------------------------------------------------
duane's Profile: http://www.excelforum.com/member.php...o&userid=11624
View this thread: http://www.excelforum.com/showthread...hreadid=492068


Gord Dibben

Nested If/Then statements
 
qwik

You kinda got it backwards.

If all values are <500 then you will always get "V"

Start with the lowest value.

=IF(B4<=100,"Z",IF(B4<=200,"Y",IF(B4<=300,"X",IF(B 4<=400,"W",IF(B4<=500,"V")))))


Gord Dibben Excel MVP

On Thu, 8 Dec 2005 20:27:08 -0600, qwik6
wrote:


Hello Everyone,
I sure could use a little help. I started with this If/Then statement
and it seems to get hung at what I understand to be the 1st "test".
I'm not sure what I'm doing wrong here......I'm loading this statement
for 8 different values (all under 500) and its supposed to bring back a
response for each value, but all it lists is the V. Any help would be
appreciated.

=IF(B4<=500,"V",IF(B4<=400,"W",IF(B4<=300,"X",IF( B4<=200,"Y",IF(B4<=100,"Z","")))))


qwik6

Nested If/Then statements
 

Thanks everyone, I really appreciate the help. Your info helped get me
over that hurdle. It sometimes sucks when you're trying to teach
yourself without anyone to work with.


--
qwik6
------------------------------------------------------------------------
qwik6's Profile: http://www.excelforum.com/member.php...o&userid=29502
View this thread: http://www.excelforum.com/showthread...hreadid=492068



All times are GMT +1. The time now is 09:05 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com