hey guys
need some help
i need to combine two if statements together.
the two if statements are below
=IF(Sheet3!$E$9=Main!I2:I41,1,0)
=IF(Sheet3!$E$13=Main!I2:I41,-1,0)
Any help will be appreciated
thanks
foad
hey guys
need some help
i need to combine two if statements together.
the two if statements are below
=IF(Sheet3!$E$9=Main!I2:I41,1,0)
=IF(Sheet3!$E$13=Main!I2:I41,-1,0)
Any help will be appreciated
thanks
foad
Last edited by foad; 03-12-2009 at 04:41 PM.
The only problem I see...is that if E9 AND E13 BOTH equal Main!I2:I41 - then the result will always be a "1" since the first criteria was met and never got to the false portion to check the second criteria. You really can't get around this in one formula since you are comparing two seperate cells to the same field and haven't dictated a priority of one IF statement over another in the situations where both criteria are met. In the formula above, I did dictate the E9 criteria as the primary...but you could switch it around if you wanted the E13 criteria instead...but you do need to choose one over the other to dictate what to do if both criteria are true.![]()
Please Login or Register to view this content.
Last edited by GuruWannaB; 03-12-2009 at 01:42 PM.
Hey pal
thanks for the formula.. it worked
i understand the reason you gave me why it would work.
but for some reason it did
so once again thank you
Ledge
Oh...it will work...but what I was trying to say...is that if E9 AND E13 were both equal to the Main!I2:I41 - and you wanted it to result with a "-1" instead of a "1" - then you would need to re-prioritize the IF statements. But glad to help!
I help because of the Pavlovian dog that resides in the inner me...so if you are happy with the results, please add to my reputation. It helps keep me motivated!
Please mark your threads as Solved once it is solved. Check the FAQ's to see how.
This doesn't make sense, your IFs refer to ranges, am I missing something?
Maybe you want to check if the value is within those ranges?
e.g
![]()
Please Login or Register to view this content.
Where there is a will there are many ways.
If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner
Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.
dont worry about it guys, thanks for your help
there was two drop down boxes, start city, end city
what i wanted to happen was when user selects the start city ($E$9),
it would look up that city in the range (L2:L200).
when it found it, it would put a 1 next to it and if not a zero, and the same for the other if statement.
so once again thanks for all your help and guruwannabe for a very quick response.
it won't work that way...
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks