ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Counting (https://www.excelbanter.com/excel-discussion-misc-queries/207675-counting.html)

Reen[_2_]

Counting
 
Is there a way to automatically count the number of entries on the spreadsheet?
Meaning a running total of rows with data entered on it?

Mike H

Counting
 
Hi,

I'm not to sure you've described the question fully but you could try this.
Alt +F11 to open VB editor. Double click 'This Workbook' and paste this in
on the right

Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)
Range("A1").Value = ActiveSheet.UsedRange.Rows.Count
End Sub

Change A1 to wherever you want the count to be

Mike

"Reen" wrote:

Is there a way to automatically count the number of entries on the spreadsheet?
Meaning a running total of rows with data entered on it?


Sheeloo[_3_]

Counting
 
Yes.

One option is to put 1 in A1
then put this in A2
=IF(B2="","",MAX(A$1:A1)+1) and copy down

This will show a running total of rows with data in Col B

"Reen" wrote:

Is there a way to automatically count the number of entries on the spreadsheet?
Meaning a running total of rows with data entered on it?



All times are GMT +1. The time now is 05:32 PM.

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