Home |
Search |
Today's Posts |
#9
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Thanks Glen that worked as well.
"Glenn" wrote: Picman wrote: I have to calculate a freight percentage based on 2 cells that on occation will not always both have a value present. Most of the time it looks like this. Sales $100.00 Freight $25.00 Percent 25.00% Sometimes I will be missing one or the other number (see below). When the sales number is not there and the freight is, then I need the percentage to be 100.00% and when the freight isn't there and the sales are, the percentage needs to read 0.00%. Sales $0.00 Freight $25.00 Percent 25.00% or Sales $100.00 Freight $0.00 Percent 0.00% I know this should be easy but I've tried different combinations of "If" and "AND" statements but can't get it to work. "Glenn" wrote: =IF(SALES=0,IF(FREIGHT=0,"You don't say what you want if both are 0",1),IF(FREIGHT=0,0,FREIGHT/SALES)) Picman wrote: If both are "0" then blank (""). OK, so remove the text between the quotes. Adding your cell references from elsewhere in the thread: =IF(B1=0,IF(B2=0,"",1),IF(B2=0,0,B2/B1)) |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
SUMPRODUCT or INDEX/MATCH for multiple conditions and multiple rec | Excel Discussion (Misc queries) | |||
How do I add multiple values that match multiple conditions? | Excel Discussion (Misc queries) | |||
Multiple conditions and multiple return values | Excel Worksheet Functions | |||
Combining Text from multiple cells under multiple conditions | Excel Worksheet Functions | |||
How to multiple conditions to validate more than 2 conditions to . | Excel Worksheet Functions |