Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Meltad
 
Posts: n/a
Default IF and AND statements

Hi,

I'm trying to write a formula to calculate a percentage...
My data is as follows:

Standard Cost = 10
Selling Price = 14
SP1 = 14
SP2 = 13
SP3 = 12

I need the formula to express...
If SP3 has a value, calculate % diff between SP3 and Standard cost. If SP3 =
0, calculate using SP2, if SP2 = 0, calculate using SP1, if SP1 = 0,
calculate using default selling price.

Help!
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bearacade
 
Posts: n/a
Default IF and AND statements


Assuming A1:B5 is your range, try this

=IF(B5 = "", IF(B4 = "", ABS(1-(B3/B1)), ABS(1-(B4/B1))),
ABS(1-(B5/B1)))


--
Bearacade
------------------------------------------------------------------------
Bearacade's Profile: http://www.excelforum.com/member.php...o&userid=35016
View this thread: http://www.excelforum.com/showthread...hreadid=548624

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Meltad
 
Posts: n/a
Default IF and AND statements

I've done this a different way, sorry I forgot to rate your reply until now

"Bearacade" wrote:


Assuming A1:B5 is your range, try this

=IF(B5 = "", IF(B4 = "", ABS(1-(B3/B1)), ABS(1-(B4/B1))),
ABS(1-(B5/B1)))


--
Bearacade
------------------------------------------------------------------------
Bearacade's Profile: http://www.excelforum.com/member.php...o&userid=35016
View this thread: http://www.excelforum.com/showthread...hreadid=548624


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



All times are GMT +1. The time now is 01:15 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"