Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 55
Default Problem using formula after formatting cells

I need to use dates and numbers in the same column and total only the numbers
using a formula. Once I changed the specific cells with the dates to "text"
so that they would not be included in the sum, I can no longer sum the
numbers. The problem doesn't go away if the cells are formated to "number",
"general" etc. The sum is always "0".
--
Stacey
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 468
Default Problem using formula after formatting cells

If you put a " ' " (without the quotes - meaning a single apostrophe)
in front of the dates -- all such cells should be eliminated from your SUM()
formula...

"Stacey" wrote:

I need to use dates and numbers in the same column and total only the numbers
using a formula. Once I changed the specific cells with the dates to "text"
so that they would not be included in the sum, I can no longer sum the
numbers. The problem doesn't go away if the cells are formated to "number",
"general" etc. The sum is always "0".
--
Stacey

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Problem using formula after formatting cells

To excel, dates are just numbers nicely formatted.

Maybe you could use two columns--one for the date and one for the data.

Or maybe you could use two columns--one for the date/data and one as an
indicator. Then you could use =sumif() to add the numeric cells that have that
indicator.

=sumif(a1:a10,"x",b1:b10)

Or you could use that indicator column and then use a formula like:
=and(isnumber(b1),left(cell("format",b1),1)="D")

This will return true if B1 is a number (including a date) and the cell has been
formatted as a date.

Then you could use:
=sumif(a1:a10,false,b1:b10)

Be aware that that =cell("Format",b1) won't recalculate if you change the format
of B1. You'll have to force a recalculation (hit F9).




Stacey wrote:

I need to use dates and numbers in the same column and total only the numbers
using a formula. Once I changed the specific cells with the dates to "text"
so that they would not be included in the sum, I can no longer sum the
numbers. The problem doesn't go away if the cells are formated to "number",
"general" etc. The sum is always "0".
--
Stacey


--

Dave Peterson
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
Grid problem with formatting cells... [email protected] New Users to Excel 4 March 5th 08 06:20 PM
Formatting & Formula Problem Titanium Excel Worksheet Functions 10 May 31st 07 10:57 PM
Currency formula/formatting problem Earl Excel Discussion (Misc queries) 4 March 20th 06 02:59 PM
Formatting cells, Need help solving a problem with excel Jonnie Z Excel Discussion (Misc queries) 1 February 4th 06 09:59 PM
Conditional formatting with dates formula problem. [email protected] Excel Discussion (Misc queries) 8 March 5th 05 11:47 PM


All times are GMT +1. The time now is 12:33 PM.

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

About Us

"It's about Microsoft Excel"