![]() |
Returning a zero
I have a worksheet with 2 sheets. The first sheet has all formulas and
depends on the second sheet. I need a formula in sheet 1 that subtracts cell a1 from cell b1 but if cell a1 is zero I want the formula to return a zero. Is this possible? |
Returning a zero
Certainly. Use something like:
=if(sheet2!a1=0,0,sheet2!b1-sheet2!a1) Regards, Fred. "Dena" wrote in message ... I have a worksheet with 2 sheets. The first sheet has all formulas and depends on the second sheet. I need a formula in sheet 1 that subtracts cell a1 from cell b1 but if cell a1 is zero I want the formula to return a zero. Is this possible? |
Returning a zero
=IF(A1=0,0,B1-A1)
"Dena" wrote: I have a worksheet with 2 sheets. The first sheet has all formulas and depends on the second sheet. I need a formula in sheet 1 that subtracts cell a1 from cell b1 but if cell a1 is zero I want the formula to return a zero. Is this possible? |
Returning a zero
Thank you!
"Fred Smith" wrote: Certainly. Use something like: =if(sheet2!a1=0,0,sheet2!b1-sheet2!a1) Regards, Fred. "Dena" wrote in message ... I have a worksheet with 2 sheets. The first sheet has all formulas and depends on the second sheet. I need a formula in sheet 1 that subtracts cell a1 from cell b1 but if cell a1 is zero I want the formula to return a zero. Is this possible? |
Returning a zero
You're welcome. Thanks for the feedback.
Regards, Fred "Dena" wrote in message ... Thank you! "Fred Smith" wrote: Certainly. Use something like: =if(sheet2!a1=0,0,sheet2!b1-sheet2!a1) Regards, Fred. "Dena" wrote in message ... I have a worksheet with 2 sheets. The first sheet has all formulas and depends on the second sheet. I need a formula in sheet 1 that subtracts cell a1 from cell b1 but if cell a1 is zero I want the formula to return a zero. Is this possible? |
All times are GMT +1. The time now is 01:54 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com