Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Excel stores dates as serial numbers. The date 1/1/2009 has value 39814.
So if each of your money values are below that value, you could use =SUMIF(A:A,"<39814") Alternatively you could use a helper column. In B1 (or some other column far to the right, and maybe hidden) enter =CELL("format",A1), copy down the column. Cells with dates will have formats of Dn (where n is a digit) while cells formatted to show 2 decimal places will have F2, while those with currency format will have C2. Very odd: a long date such as 1 January 2010 seems to have format G (general) - I am using Excel 2010 beta To sum currency formatted cell: =SUMIF(B1:B100,"C2",A1:A100) Note: the CELL function is not volatile so if you reformat a cell the formula will not update until the worksheet is next recalculated. You can force this with F9. If the helper column is not acceptable, maybe someone with give you a VBA solution. best wishes -- Bernard Liengme Microsoft Excel MVP http://people.stfx.ca/bliengme "Starbuck82" wrote in message ... I have both dates and currency in the same column. How do I sum the column based on format of the cell? Specifically, how do I sumif only the cells containing currency? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Sumif formula that uses "contains" rather than "equals" | Excel Discussion (Misc queries) | |||
If a cell equals _, at the next row that equals _, return value fr | Excel Worksheet Functions | |||
if a:a (range) equals january and c:c equals gas then add g:g ($) | Excel Worksheet Functions | |||
custom filter does not work when selecting 'equals' X AND 'equals' | Excel Discussion (Misc queries) | |||
how to write 'not equals blank' criteria in SUMIF | Excel Worksheet Functions |