VBA: Count the rows in a Selection
If you ever need to count the number of rows that were selected, use Selection.Rows.Count Put this in a module: Public Sub CountMyRows() MsgBox Selection.Rows.Count End Sub
View ArticleVBA: Count the sheets in a Workbook
If you ever need to count the number of sheets in a workbook, use Application.Sheets.Count Put this in a module: Public Sub CountMySheets() MsgBox Application.Sheets.Count End Sub
View ArticleVBA: Count the Columns in a Selection
If you ever need to count the number of Columns that were selected, use Selection.Columns.Count Put this in a module: Public Sub CountMyColumns() MsgBox Selection.Columns.Count End Sub
View ArticleVBA: Count the Number of Used Rows
The following code will return in a message box the total number of rows used in a worksheet. Empty rows are considered used if data follows the empty row. MsgBox ActiveSheet.UsedRange.Rows.Count
View ArticleCount Characters in a Cell
To count the total characters (including spaces) in cell A1: =len(A1) To count the total characters (not including spaces) in cell A1: =LEN(SUBSTITUTE(A1," ","")) To count the total specific characters...
View ArticleVBA: User Defined Function that Counts Selected Cells
The following function will examine a range of Excel cells and return the number that fall within a specified range: Function Count_Selected_Cells(Data_Range As Range, Min As Double, Max As Double) As...
View ArticleTotal, Average, Count, Min, Max
There are quick ways to use these everyday functions: Click the cell you wish to display the new value (ie – total) Select the sum button from the toolbar Check the range is correct (for the values you...
View Article
More Pages to Explore .....