IF THEN AND Statement Help
Solved/Closed
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
-
Dec 9, 2008 at 01:21 PM
ralphl - Dec 15, 2008 at 08:44 AM
ralphl - Dec 15, 2008 at 08:44 AM
Related:
- IF THEN AND Statement Help
- Fenix internet on bank statement - Guide
- An if statement nested within another if statement will produce how many possible results? - Guide
- Excel if statement - Guide
- Application for bank statement sbi - Guide
- Vba case statement with string - Guide
27 responses
aquarelle
Posts
7140
Registration date
Saturday April 7, 2007
Status
Moderator
Last seen
March 25, 2024
491
Dec 9, 2008 at 03:41 PM
Dec 9, 2008 at 03:41 PM
I have 5.8 in B2 I have 1.012 in B9
With your formula, the result is 5.7 not 5.8
With your formula, the result is 5.7 not 5.8
aquarelle
Posts
7140
Registration date
Saturday April 7, 2007
Status
Moderator
Last seen
March 25, 2024
491
Dec 10, 2008 at 05:23 PM
Dec 10, 2008 at 05:23 PM
Normal that it doesn't work because as I said to the message N°<11>, you have to write =IF(AND(B2<=5.9, B9=1.012), B2-0.1,""), cause "greater than or equal "sign is "<=" in Excel. Try it.
TheParoxysm
Posts
169
Registration date
Sunday December 7, 2008
Status
Member
Last seen
March 25, 2011
74
Dec 9, 2008 at 01:39 PM
Dec 9, 2008 at 01:39 PM
=IF(AND(test1,test2,test3,...),true result, false result)
Example: If A1>B1 and C1<D1 then the result is 5, otherwise it's 0. As a nested IF statement:
=IF(A1>B1,IF(C1<D1,5,0),0)
Using AND, it's a little neater:
=IF(AND(A1>B1,C1<D1),5,0)
Remove the absolute cell reference and try it. Some people overuse absolute cell references, and cause themselves a headache when it doesn't work the way they THOUGHT it worked when they changed the table.
Example: If A1>B1 and C1<D1 then the result is 5, otherwise it's 0. As a nested IF statement:
=IF(A1>B1,IF(C1<D1,5,0),0)
Using AND, it's a little neater:
=IF(AND(A1>B1,C1<D1),5,0)
Remove the absolute cell reference and try it. Some people overuse absolute cell references, and cause themselves a headache when it doesn't work the way they THOUGHT it worked when they changed the table.
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
Dec 9, 2008 at 01:55 PM
Dec 9, 2008 at 01:55 PM
So basically us it like so:
=IF(AND(B2<"5.9",B9="1.012"),B2-"0.1",)
Thanks
=IF(AND(B2<"5.9",B9="1.012"),B2-"0.1",)
Thanks
Didn't find the answer you are looking for?
Ask a question
TheParoxysm
Posts
169
Registration date
Sunday December 7, 2008
Status
Member
Last seen
March 25, 2011
74
Dec 9, 2008 at 01:58 PM
Dec 9, 2008 at 01:58 PM
Yep. Also, and I just realized this, take your numbers out of quotation marks.
=IF(AND(B2<5.9, B9=1.012), B2-0.1)
Hopefully this helps!
=IF(AND(B2<5.9, B9=1.012), B2-0.1)
Hopefully this helps!
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
Dec 9, 2008 at 02:38 PM
Dec 9, 2008 at 02:38 PM
For some reason I'm getting a "FALSE" in the cell. Here is my formula again:
=IF(AND(B2<5.9,B9=1.012),B2-0.1)
Thanks
=IF(AND(B2<5.9,B9=1.012),B2-0.1)
Thanks
aquarelle
Posts
7140
Registration date
Saturday April 7, 2007
Status
Moderator
Last seen
March 25, 2024
491
Dec 9, 2008 at 02:54 PM
Dec 9, 2008 at 02:54 PM
Hi,
It is normal that you have this error because you forgot to indicate what will happen (then the formula to calculate) if this condition is not respected.
=IF(AND(B2<5.9,B9=1.012),B2-0.1,false result)
Best regards
It is normal that you have this error because you forgot to indicate what will happen (then the formula to calculate) if this condition is not respected.
=IF(AND(B2<5.9,B9=1.012),B2-0.1,false result)
Best regards
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
Dec 9, 2008 at 03:24 PM
Dec 9, 2008 at 03:24 PM
The funny part is that it's right. I should get an answer and it's giving a false answer. I have 5.8 in B2 I have 1.012 in B9 so essentially i should get 5.8 as an answer. But it's not.
Help
Help
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
Dec 9, 2008 at 04:08 PM
Dec 9, 2008 at 04:08 PM
Im sorry I have 5.9 in B2. The answer should be 5.8.
aquarelle
Posts
7140
Registration date
Saturday April 7, 2007
Status
Moderator
Last seen
March 25, 2024
491
Dec 9, 2008 at 04:20 PM
Dec 9, 2008 at 04:20 PM
Write your formula like this :
=IF(AND(B2<=5.9,B9=1.012),B2-0.1,false result)
=IF(AND(B2<=5.9,B9=1.012),B2-0.1,false result)
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
Dec 9, 2008 at 07:15 PM
Dec 9, 2008 at 07:15 PM
For some reason it does not take. Talk about a headache!
All the Cells have the correct info and not dice!
All the Cells have the correct info and not dice!
aquarelle
Posts
7140
Registration date
Saturday April 7, 2007
Status
Moderator
Last seen
March 25, 2024
491
Dec 10, 2008 at 03:23 AM
Dec 10, 2008 at 03:23 AM
Hi,
Could you tell me what is happened, what sort of result you had ?
Please load a brief example of your excel file (without any private or personal data) on https://authentification.site then copy past the created link to your next answer.
See you
Could you tell me what is happened, what sort of result you had ?
Please load a brief example of your excel file (without any private or personal data) on https://authentification.site then copy past the created link to your next answer.
See you
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
Dec 10, 2008 at 05:58 AM
Dec 10, 2008 at 05:58 AM
Ok, here it is
https://authentification.site/914280127.html
The thing is that it does not give the right answer. It gives a blank answer/nothing in the cell.
Thanks so much.
https://authentification.site/914280127.html
The thing is that it does not give the right answer. It gives a blank answer/nothing in the cell.
Thanks so much.
aquarelle
Posts
7140
Registration date
Saturday April 7, 2007
Status
Moderator
Last seen
March 25, 2024
491
Dec 10, 2008 at 06:22 AM
Dec 10, 2008 at 06:22 AM
Arff, I have Office 2003, so could you save it to the Excel 2003 format, load it again and copy/past the new link, please.
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
Dec 10, 2008 at 02:26 PM
Dec 10, 2008 at 02:26 PM
Here you go...
https://authentification.site/894439785.html
Thanks again
https://authentification.site/894439785.html
Thanks again
aquarelle
Posts
7140
Registration date
Saturday April 7, 2007
Status
Moderator
Last seen
March 25, 2024
491
Dec 10, 2008 at 03:27 PM
Dec 10, 2008 at 03:27 PM
Ok, what I have seen is that your cells format is in Text format then you have to put it in Number format otherwise Excel can't calculate the formula.
See you
See you
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
Dec 10, 2008 at 04:45 PM
Dec 10, 2008 at 04:45 PM
Ok, So went ahead and changed that cell to number and I still don't get a correct answer.
Any other thought?
Any other thought?
aquarelle
Posts
7140
Registration date
Saturday April 7, 2007
Status
Moderator
Last seen
March 25, 2024
491
Dec 10, 2008 at 04:50 PM
Dec 10, 2008 at 04:50 PM
You have to change the format for all cells. Did you?
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
Dec 10, 2008 at 04:51 PM
Dec 10, 2008 at 04:51 PM
All of them are in number
aquarelle
Posts
7140
Registration date
Saturday April 7, 2007
Status
Moderator
Last seen
March 25, 2024
491
Dec 10, 2008 at 04:56 PM
Dec 10, 2008 at 04:56 PM
Is there an error written ? What is happen ? I don't understand because it works for me.
ralphl
Posts
16
Registration date
Monday December 8, 2008
Status
Member
Last seen
December 12, 2008
Dec 10, 2008 at 05:11 PM
Dec 10, 2008 at 05:11 PM
It does not give the number that need. The answer should be 5.8, since i have it like follows, it does not show anything:
=IF(AND(B2<5.9, B9=1.012), B2-0.1,"")
=IF(AND(B2<5.9, B9=1.012), B2-0.1,"")
Dec 9, 2008 at 03:46 PM
Dec 9, 2008 at 04:03 PM
I use it every day for my work and when I need new functions to facilitate my work, I search in Excel help file or to Internet.