Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
trixma
 
Posts: n/a
Default Linking two IF statements together


In excel you can only have 7 nested if statements in one cell, i need a
10 nested if statement and my if statements are below

Cell A1 =IF(B17=0,B2+(Input!B2-B17)/Input!B2,IF(B17+C17=0,C2
-1+((Input!B2-B17)-C17)/Input!B2,IF(B17+C17+D17=0,D2
-1+(((Input!B2-B17)-C17)-D17)/Input!B2,IF(B17+C17+D17+E17=0,E2
-1+((((Input!B2-B17)-C17)-D17)-E17)/Input!B2,IF(B17+C17+D17+E17+F17=0,
F2-1+(((((Input!B2-B17)-C17)-D17)-E17)-F17)/Input!B2,IF(B17+C17+D17+E17+F17+
G17=0,G2-1+((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)/Input!B2,
IF(B17+C17+D17+E17+F17+G17+H17=0,
H2-1+(((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17-H17)/Input!B2,
))))))))

Cell B1 =IF(B17+C17+D17+E17+F17+G17+H17+I17=0,I2 - 1
+((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)/Input!B2,IF(B17+C17+D17+E17+F17+G17+H17+I17+J17=0 ,
J2 - 1
+(((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)-J17)/Input!B2,IF(B17+C17+D17+E17+F17+G17+H17+I17+J17
+ K17=0, K2 -1
+((((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)-J17)-K17)/Input!B2,IF(B17+C17+D17+E17+F17+G17+H17+I17+J17+K1 7
+ L17=0, L2 -1 +
(((((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)-J17)-K17)-L17)/Input!B2))))

I tried using goto to link the 2 if statements together with no luck. I
have to use the if statements like they are and i cannot alter them in
any way or use hidden fields. Does anyone know how I could link these
to statements together?

Thanks Trixma.


--
trixma
------------------------------------------------------------------------
trixma's Profile: http://www.excelforum.com/member.php...o&userid=25702
View this thread: http://www.excelforum.com/showthread...hreadid=471643

  #2   Report Post  
duane
 
Posts: n/a
Default


try this - note default to cell B1 if none of first six conditions are
met. Seveneth condition now in cell B1

Cell A1 =IF(B17=0,B2+(Input!B2-B17)/Input!B2,IF(B17+C17=0,C2
-1+((Input!B2-B17)-C17)/Input!B2,IF(B17+C17+D17=0,D2
-1+(((Input!B2-B17)-C17)-D17)/Input!B2,IF(B17+C17+D17+E17=0,E2
-1+((((Input!B2-B17)-C17)-D17)-E17)/Input!B2,IF(B17+C17+D17+E17+F17=0,
F2-1+(((((Input!B2-B17)-C17)-D17)-E17)-F17)/Input!B2,IF(B17+C17+D17+E17+F17+
G17=0,G2-1+((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)/Input!B2,
B1))))))

Cell B1 =IF(B17+C17+D17+E17+F17+G17+H17=0,
H2-1+(((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)/Input!B2,
IF(B17+C17+D17+E17+F17+G17+H17+I17=0,I2 - 1
+((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)/Input!B2,IF(B17+C17+D17+E17+F17+G17+H17+I17+J17=0 ,
J2 - 1
+(((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)-J17)/Input!B2,IF(B17+C17+D17+E17+F17+G17+H17+I17+J17
+ K17=0, K2 -1
+((((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)-J17)-K17)/Input!B2,IF(B17+C17+D17+E17+F17+G17+H17+I17+J17+K1
7 + L17=0, L2 -1 +
(((((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)-J17)-K17)-L17)/Input!B2)))))


--
duane


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

  #3   Report Post  
JE McGimpsey
 
Posts: n/a
Default

If you really can't alter the cells in any way (and that's too bad,
because they could be simplified immensely), the only way I can think of
to "link" them would be to do something like:

C1: =IF(A1,A1,B1)

If that's not what you mean by "link", post back with an example.

In article ,
trixma wrote:

In excel you can only have 7 nested if statements in one cell, i need a
10 nested if statement and my if statements are below

Cell A1 =IF(B17=0,B2+(Input!B2-B17)/Input!B2,IF(B17+C17=0,C2
-1+((Input!B2-B17)-C17)/Input!B2,IF(B17+C17+D17=0,D2
-1+(((Input!B2-B17)-C17)-D17)/Input!B2,IF(B17+C17+D17+E17=0,E2
-1+((((Input!B2-B17)-C17)-D17)-E17)/Input!B2,IF(B17+C17+D17+E17+F17=0,
F2-1+(((((Input!B2-B17)-C17)-D17)-E17)-F17)/Input!B2,IF(B17+C17+D17+E17+F17+
G17=0,G2-1+((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)/Input!B2,
IF(B17+C17+D17+E17+F17+G17+H17=0,
H2-1+(((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17-H17)/Input!B2,
))))))))

Cell B1 =IF(B17+C17+D17+E17+F17+G17+H17+I17=0,I2 - 1
+((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)/Input!B2,IF(B17+C17+
D17+E17+F17+G17+H17+I17+J17=0,
J2 - 1
+(((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)-J17)/Input!B2,IF(B1
7+C17+D17+E17+F17+G17+H17+I17+J17
+ K17=0, K2 -1
+((((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)-J17)-K17)/Input!B2
,IF(B17+C17+D17+E17+F17+G17+H17+I17+J17+K17
+ L17=0, L2 -1 +
(((((((((((Input!B2-B17)-C17)-D17)-E17)-F17)-G17)-H17)-I17)-J17)-K17)-L17)/Inp
ut!B2))))

I tried using goto to link the 2 if statements together with no luck. I
have to use the if statements like they are and i cannot alter them in
any way or use hidden fields. Does anyone know how I could link these
to statements together?

Thanks Trixma.

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
Dynamic Linking user33 Excel Discussion (Misc queries) 1 August 3rd 05 08:38 PM
Nested IF statements John Simons Excel Worksheet Functions 14 February 16th 05 06:17 AM
Have to use cursor keys cannot use mouse in excel when linking fo. LUFC Excel Worksheet Functions 0 January 31st 05 09:51 AM
Linking Workbooks Dede McEachern Excel Worksheet Functions 0 January 21st 05 08:27 PM
If statements Mark Excel Worksheet Functions 3 November 2nd 04 08:39 PM


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