ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Using auto sum feature (https://www.excelbanter.com/excel-discussion-misc-queries/159566-using-auto-sum-feature.html)

Dave

Using auto sum feature
 
Hi, I know how to use auto sum feature using numbers,but I need it to pick up
a letter rather than numbers. Can this be done, as I need to use "H" for
holiday,but need this to be deducted off a spread sheet every time it is used.

Thanks

Gord Dibben

Using auto sum feature
 
Assuming you have days worked in column A with the odd "H" for holiday thrown
in.

=SUM(A1:A30)-COUNTIF(A1:A30,"H")


Gord Dibben MS Excel MVP


On Tue, 25 Sep 2007 07:36:00 -0700, Dave wrote:

Hi, I know how to use auto sum feature using numbers,but I need it to pick up
a letter rather than numbers. Can this be done, as I need to use "H" for
holiday,but need this to be deducted off a spread sheet every time it is used.

Thanks



Bob Phillips

Using auto sum feature
 
Nope. You need something like=SUM(IF(H1:H3="H",1,H1:H3))

which is an array formula, it should be committed with Ctrl-Shift-Enter, not
just Enter.
Excel will automatically enclose the formula in braces (curly brackets), do
not try to do this manually.
When editing the formula, it must again be array-entered.

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"Dave" wrote in message
...
Hi, I know how to use auto sum feature using numbers,but I need it to pick
up
a letter rather than numbers. Can this be done, as I need to use "H" for
holiday,but need this to be deducted off a spread sheet every time it is
used.

Thanks




Dave Peterson

Using auto sum feature
 
Maybe you can use:
=countif(a1:a10,"h")
to count the number of cells that contain H.

I don't think that you'll be able to use the autosum icon to implement this.

Dave wrote:

Hi, I know how to use auto sum feature using numbers,but I need it to pick up
a letter rather than numbers. Can this be done, as I need to use "H" for
holiday,but need this to be deducted off a spread sheet every time it is used.

Thanks


--

Dave Peterson


All times are GMT +1. The time now is 07:15 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com