ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   How can I sum the number of check boxs, checked in excell 2003 (https://www.excelbanter.com/excel-discussion-misc-queries/107470-how-can-i-sum-number-check-boxs-checked-excell-2003-a.html)

Arfa

How can I sum the number of check boxs, checked in excell 2003
 
I would like to total the number of check boxs in a column, that have been
checked.

Using Excel 2003

Thanks
AL

Bob Phillips

How can I sum the number of check boxs, checked in excell 2003
 
Dim chk As CheckBox
Dim c As Long

For Each chk In ActiveSheet.Checkboxes
If chk.Value = Then c = c + 1
Next chk

MsgBox c


--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"Arfa" wrote in message
...
I would like to total the number of check boxs in a column, that have been
checked.

Using Excel 2003

Thanks
AL




Toppers

How can I sum the number of check boxs, checked in excell 2003
 
You will need VBA code to do this.

Personally, i think a a "better" solution is to use Data Validation with
YES/NO (or Y/N)options and then use (for example) SUMIF to calculate number
"checked" i.e answer of "YES" (or "Y")

=SUMIF(A2:A100,"Y")



"Arfa" wrote:

I would like to total the number of check boxs in a column, that have been
checked.

Using Excel 2003

Thanks
AL


Bob Phillips

How can I sum the number of check boxs, checked in excell 2003
 
You are right John, but he could use checkboxes and link that to cells (D1,
D2 etc.) and then just use

=COUNTIF(D1:D10,TRUE)

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"Toppers" wrote in message
...
You will need VBA code to do this.

Personally, i think a a "better" solution is to use Data Validation with
YES/NO (or Y/N)options and then use (for example) SUMIF to calculate

number
"checked" i.e answer of "YES" (or "Y")

=SUMIF(A2:A100,"Y")



"Arfa" wrote:

I would like to total the number of check boxs in a column, that have

been
checked.

Using Excel 2003

Thanks
AL





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

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