View Full Version : [SOLVED:] Counting Cells
Could anybody let me know how to make a function in Excel to count the number of cells with only value in a column excluding blank cells.
Jacob Hilderbrand
05-03-2005, 07:18 AM
Use the CountA function.
=CountA(A:A)
austenr
05-03-2005, 07:19 AM
Try this:
Sub CountNonBlankCells() 'Returns a count of non-blank cells in a selection
Dim myCount As Integer 'using the CountA ws function (all non-blanks)
myCount = Application.CountA(Selection)
MsgBox "The number of non-blank cell(s) in this selection is : "_
& myCount, vbInformation, "Count Cells"
End Sub
Thanks everybody who has tried to help me to solve the question "counting cells"
Thanks!
Jacob Hilderbrand
05-04-2005, 09:55 AM
Glad to help :beerchug:
Take Care
Powered by vBulletin® Version 4.2.5 Copyright © 2025 vBulletin Solutions Inc. All rights reserved.