![]() |
If..else..then statement
I'm trying to write this compare statement, but I keep getting errors about
to many arguements: In Cell C20 IF C10=0, then C15 ElseIF C15=0, then C10 ElseIF C15=0 and C10=0 then Average(C10,C15) Else 0 Thanks in advance |
If..else..then statement
Jeff,
table for all the possible commbinations of C10 & c15 looks like this c10 c15 answer 1 0 0.5 0 1 0.5 0 0 0 1 1 1 From your description I belive the answer in each case is as indicated above so =average(c10,c15) should work Mike "Jeff Metcalf" wrote: I'm trying to write this compare statement, but I keep getting errors about to many arguements: In Cell C20 IF C10=0, then C15 ElseIF C15=0, then C10 ElseIF C15=0 and C10=0 then Average(C10,C15) Else 0 Thanks in advance |
If..else..then statement
Hi,
I should have added that if this is wrong please put the answers you expect in each case. Mike "Mike H" wrote: Jeff, table for all the possible commbinations of C10 & c15 looks like this c10 c15 answer 1 0 0.5 0 1 0.5 0 0 0 1 1 1 From your description I belive the answer in each case is as indicated above so =average(c10,c15) should work Mike "Jeff Metcalf" wrote: I'm trying to write this compare statement, but I keep getting errors about to many arguements: In Cell C20 IF C10=0, then C15 ElseIF C15=0, then C10 ElseIF C15=0 and C10=0 then Average(C10,C15) Else 0 Thanks in advance |
If..else..then statement
Sorry, this is what I what....
c10 c15 answer 1 0 1 0 1 1 0 0 0 1 1 1 5 2 3.5 Thanks "Mike H" wrote: Hi, I should have added that if this is wrong please put the answers you expect in each case. Mike "Mike H" wrote: Jeff, table for all the possible commbinations of C10 & c15 looks like this c10 c15 answer 1 0 0.5 0 1 0.5 0 0 0 1 1 1 From your description I belive the answer in each case is as indicated above so =average(c10,c15) should work Mike "Jeff Metcalf" wrote: I'm trying to write this compare statement, but I keep getting errors about to many arguements: In Cell C20 IF C10=0, then C15 ElseIF C15=0, then C10 ElseIF C15=0 and C10=0 then Average(C10,C15) Else 0 Thanks in advance |
If..else..then statement
I'm confused about averaging 2 zero cells and why you started a new thread
but try this =IF(C10=0,C15,IF(C15=0,C10,AVERAGE(C10,C15))) Mike "Jeff Metcalf" wrote: Sorry, this is what I what.... c10 c15 answer 1 0 1 0 1 1 0 0 0 1 1 1 5 2 3.5 Thanks "Mike H" wrote: Hi, I should have added that if this is wrong please put the answers you expect in each case. Mike "Mike H" wrote: Jeff, table for all the possible commbinations of C10 & c15 looks like this c10 c15 answer 1 0 0.5 0 1 0.5 0 0 0 1 1 1 From your description I belive the answer in each case is as indicated above so =average(c10,c15) should work Mike "Jeff Metcalf" wrote: I'm trying to write this compare statement, but I keep getting errors about to many arguements: In Cell C20 IF C10=0, then C15 ElseIF C15=0, then C10 ElseIF C15=0 and C10=0 then Average(C10,C15) Else 0 Thanks in advance |
If..else..then statement
I didn't start 2 threads...I don't know how that happened.
I'm not trying to average 2 zero cells really...I just want it to show 0 if the corresponding cells are both 0. The sheet calculates profit margin from 2 different areas of work. So if they salesperson only has things in the 'write in' area, then I only want to show that margin percentage. If he only has items in the DB connected area, then I only want it to show that margin. But if he has items in both areas, then I need the profit margin calculated from both. Maybe I'm going about this wrong? "Mike H" wrote: I'm confused about averaging 2 zero cells and why you started a new thread but try this =IF(C10=0,C15,IF(C15=0,C10,AVERAGE(C10,C15))) Mike "Jeff Metcalf" wrote: Sorry, this is what I what.... c10 c15 answer 1 0 1 0 1 1 0 0 0 1 1 1 5 2 3.5 Thanks "Mike H" wrote: Hi, I should have added that if this is wrong please put the answers you expect in each case. Mike "Mike H" wrote: Jeff, table for all the possible commbinations of C10 & c15 looks like this c10 c15 answer 1 0 0.5 0 1 0.5 0 0 0 1 1 1 From your description I belive the answer in each case is as indicated above so =average(c10,c15) should work Mike "Jeff Metcalf" wrote: I'm trying to write this compare statement, but I keep getting errors about to many arguements: In Cell C20 IF C10=0, then C15 ElseIF C15=0, then C10 ElseIF C15=0 and C10=0 then Average(C10,C15) Else 0 Thanks in advance |
All times are GMT +1. The time now is 07:09 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com