View Single Post
  #9   Report Post  
Posted to microsoft.public.excel.misc
expect_ed expect_ed is offline
external usenet poster
 
Posts: 53
Default Sumif Fails w Date as Text

Well, I actually simplified that col a bit to shorten the description.
The cells in row C actually contain a formula:
=IF(Sheet2!M37="",Sheet2!L37,Sheet2!M37)
because I am pasting a worksheet into Sheet 2 that will have work hr values
either in col L (original) or col M (updated).

So when I use the paste special multiply everything changes to #VALUE errors??

The pasted cells in sheet2 come in as General formatted.

Thanks again for your help.
ed

"Roger Govier" wrote:

Hi I
in a blank cell on your sheet enter 1
Copy that cell
Mark the range of your "non numeric data"
Paste SpecialMultiply

--
Regards
Roger Govier



"expect_ed" wrote in message
...
Yes, that seems to be the problem. Even when I set the format to numeric
the
cells remain as non-numeric. If I try =value(c10) I get a #Value error.

Any suggestions for forcing the cells to numbers???
thanks for your help.
ed

"Roger Govier" wrote:

Yes, I misread your posting.
Your dates are in A and the values to be summed are in C.
It works absolutely fine for me. There must be something wrong with your
data.
Perhaps the values in column C are text, not numeric. That would give a
result of 0.
Try testing columns C with =ISNUMBER(C1) and copying down.

--
Regards
Roger Govier



"expect_ed" wrote in message
...
I don't think that is correct. According to Excel the first parameter
is
the
compare range and the 3rd parameter is the cells to be summed.
In any case I tried switching it and still get zero.
Thanks anyway.
ed

"Roger Govier" wrote:

Hi Ed

I think you have the formula the wrong way round.
You are saying the "dates" are in C and the values to be summed in A.
Try
=SUMIF(C10:C100,P1,A10:A100)


--
Regards
Roger Govier



"expect_ed" wrote in message
...
I have a column (A) that calculates a date to the nearest 1st of the
month
based on a date in another column on another sheet (Sheet2!G).
The calculation is of the form =VALUE(LEFT(Sheet2!G43,2))+1 & "/1"
Column A is formatted as text.
Then I have a set of cells (P1 to P8) that calculates the first of
the
month
out 2 to 10 months.
That calculation is of the form = (MONTH(TODAY())+#) & "/1" where #
varies
from 2 to 10.
So in column A I get values like 10/1, 12/1, 11/1, etc. and in P I
also
get
similar values. Column P is also formatted as text.
In Column C there are work hours associated with the month starts in
col A
and I want to total the work hours for each month start, so in
Column H
If
have the following calculations:

H1: =SUMIF(A10:A100,P1,C10:C100)
H2: =SUMIF(A10:A100,P2,C10:C100)
etc.

So when P2 = 10/1 I would expect H2 to contain the total of any
cells
in C
that have a value of 10/1. Instead I get a zero.

I have tried to confirm that the values match with the formula
=IF(P2 =
A5,1,0) where A5 displays 10/1 and the result is a 1, meaning that
the
cells
match, but I still get only a 0 in H2.

Any help appreciated.
thanks
ed