Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Rum Rum is offline
external usenet poster
 
Posts: 16
Default Differenec formula: Dnt need '0' as a result;Rather have a blank c

Hi,

I have an excel sheet with data in columns A & B on TAB 1 and I am trying to
have the DIFFERENCE of TAB 1-Cell A1 & B1 in TAB 2-Cell A1.

My Cells A1 & B1 of TAB1 are empty (have nothing in them) and when I apply
the formula I get "0" as result in Cell A1-TAB 2.

Is there a way to NOT get '0' in the result cell with the formula still
being in there even when your data cells are empty?

Please help.

Thanks
Regards
Rum
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 515
Default Differenec formula: Dnt need '0' as a result;Rather have a blank c

Start your formulae with an IF statement, to check whether Cell A in Tab 1
has a value. =IF(TAB1!A1="","",TAB1!A1-TAB1!B1)
--
HTH

Kassie

Replace xxx with hotmail


"Rum" wrote:

Hi,

I have an excel sheet with data in columns A & B on TAB 1 and I am trying to
have the DIFFERENCE of TAB 1-Cell A1 & B1 in TAB 2-Cell A1.

My Cells A1 & B1 of TAB1 are empty (have nothing in them) and when I apply
the formula I get "0" as result in Cell A1-TAB 2.

Is there a way to NOT get '0' in the result cell with the formula still
being in there even when your data cells are empty?

Please help.

Thanks
Regards
Rum

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,059
Default Differenec formula: Dnt need '0' as a result;Rather have a blank c

"Rum" wrote:
Is there a way to NOT get '0' in the result cell with the formula
still being in there even when your data cells are empty?


=if(and(tab1!A1="", tab1!B1=""), "", tab1!A1 - tab1!B1)

Alternatively:

=if(countif(tab1!A1:B1,"")=2, "", tab1!A1 - tab1!B1)

Caveat: In both cases, it would be prudent to write n(tab1!A1) -
n(tab1!B1), just in case either A1 or B1 might be "", not truly empty.


----- original message -----

"Rum" wrote in message
...
Hi,

I have an excel sheet with data in columns A & B on TAB 1 and I am trying
to
have the DIFFERENCE of TAB 1-Cell A1 & B1 in TAB 2-Cell A1.

My Cells A1 & B1 of TAB1 are empty (have nothing in them) and when I apply
the formula I get "0" as result in Cell A1-TAB 2.

Is there a way to NOT get '0' in the result cell with the formula still
being in there even when your data cells are empty?

Please help.

Thanks
Regards
Rum


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,572
Default Differenec formula: Dnt need '0' as a result;Rather have a blank c

Try this:

=IF(COUNT(Sheet1!A1:B1)=2,Sheet1!A1-Sheet1!B1,"")
--
HTH,

RD

---------------------------------------------------------------------------
Please keep all correspondence within the NewsGroup, so all may benefit !
---------------------------------------------------------------------------

"Rum" wrote in message
...
Hi,

I have an excel sheet with data in columns A & B on TAB 1 and I am trying
to
have the DIFFERENCE of TAB 1-Cell A1 & B1 in TAB 2-Cell A1.

My Cells A1 & B1 of TAB1 are empty (have nothing in them) and when I apply
the formula I get "0" as result in Cell A1-TAB 2.

Is there a way to NOT get '0' in the result cell with the formula still
being in there even when your data cells are empty?

Please help.

Thanks
Regards
Rum



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 22,906
Default Differenec formula: Dnt need '0' as a result;Rather have a blank c

=IF(Sheet1!A1-Sheet1!B1=0,"",Sheet1!A1-Sheet1!B1)

Or if you want to see a zero when the difference evaluates to a real zero

=IF(AND(Sheet1!A1="",(Sheet1!B1="")),"",Sheet1!A1-Sheet1!B1)


Gord Dibben MS Excel MVP

On Tue, 28 Jul 2009 12:03:01 -0700, Rum
wrote:

Hi,

I have an excel sheet with data in columns A & B on TAB 1 and I am trying to
have the DIFFERENCE of TAB 1-Cell A1 & B1 in TAB 2-Cell A1.

My Cells A1 & B1 of TAB1 are empty (have nothing in them) and when I apply
the formula I get "0" as result in Cell A1-TAB 2.

Is there a way to NOT get '0' in the result cell with the formula still
being in there even when your data cells are empty?

Please help.

Thanks
Regards
Rum


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
I need a gap when the result of a formula is blank or zero vsoler Charts and Charting in Excel 3 June 12th 08 04:27 PM
formula result blank Leonard Excel Worksheet Functions 0 January 11th 07 08:45 AM
How to get Blank into a cell as a result of a formula jkb_junk Excel Worksheet Functions 2 January 10th 07 03:37 AM
Pasteing formula gives blank result garin Excel Worksheet Functions 0 August 3rd 06 01:11 PM
IF statement when formula result is blank Bonnie Excel Worksheet Functions 2 September 1st 05 05:08 PM


All times are GMT +1. The time now is 04:21 PM.

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"