[Solved] How do I count cells?

Discuss the spreadsheet application
Post Reply
kh92
Posts: 4
Joined: Sun Apr 08, 2012 4:43 pm

[Solved] How do I count cells?

Post by kh92 »

Basically I want to click ctrl and highlight a few cells then have it tell me how many cells I've highlighted. Should be a basic function of Calc right?
Last edited by MrProgrammer on Sat May 30, 2020 3:57 pm, edited 1 time in total.
Reason: Tagged ✓ [Solved]
OpenOffice 3.2.0 on Linux Mint 9 Isadora
eremmel
Posts: 1080
Joined: Tue Dec 30, 2008 1:15 am

Re: How do I count cells?

Post by eremmel »

In the status bar there is by default mentioned 'sum=...' Right click on this gives list of other functions. You can choose count() or countA(). This will count the selected cells that are not-empty. I think that it is not possible to 'see' the amount of selected empty cells.
It's Microsoft marketing that tells you computers are qualified for non-technicians
W11 22H2 (build 22621), LO 7.4.2.3(x64)
User avatar
MrProgrammer
Moderator
Posts: 5470
Joined: Fri Jun 04, 2010 7:57 pm
Location: Wisconsin, USA

Re: How do I count cells?

Post by MrProgrammer »

kh92 wrote:I want to click ctrl and highlight a few cells then have it tell me how many cells I've highlighted.
It's not clear if you want the count of the cells or the dimensions of those cells (rows and columns). I will assume the latter because eremmel has suggested a method for the former.
  1. If the sheet is unprotected, select an unused cell, type =, select the desired range, note the displayed row/column tool tip, and press Escape. This requires option (OpenOffice.org > Preferences on a Mac; Tools > Options on other platforms) OpenOffice.org > General > Help > Tips.
  2. Otherwise, look at name box and do simple mental arithmetic. For example if it shows C121:E226 that's 106 rows and three columns (318 cells). The name box is the area to left of ⨍ₓ Σ = in the formula bar. (View > Formula Bar)
  3. If the cells are not empty, right click the status bar area to the left of the zoom slider and select COUNTA. Drag across one column vertically to see row count. Drag across one row horizontally to see column count.
  4. If mental arithmetic is too hard for you, the sheet is protected, and the cells are empty see Counting rows for macro approaches.
  5. You could check the Extensions site to see if any of them offer that feature. Persist if the site doesn't open.
If this answered your question please go to your first post use the Edit button and add [Solved] to the start of the title. You can select the green checkmark icon at the same time.
Mr. Programmer
AOO 4.1.7 Build 9800, MacOS 13.7.8, iMac Intel.   The locale for any menus or Calc formulas in my posts is English (USA).
kh92
Posts: 4
Joined: Sun Apr 08, 2012 4:43 pm

Re: How do I count cells?

Post by kh92 »

Any less complicated ways of doing this? All I want to do is hit Ctrl, select a few cells, and see how many cells I've selected. Sounds like the most basic thing imaginable. Am I to understand Open Office doesn't support something so unbelievably basic like this?
OpenOffice 3.2.0 on Linux Mint 9 Isadora
FJCC
Moderator
Posts: 9644
Joined: Sat Nov 08, 2008 8:08 pm
Location: Colorado, USA

Re: How do I count cells?

Post by FJCC »

If the cells are not empty, then eremmel's method provides a simple solution. If the cells are empty, then I don't know of a way to display how many are selected. If you are looking for a count of cells regardless of whether they are empty, can you explain why? Maybe there is another way to get where you want to go.
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
User avatar
kingfisher
Volunteer
Posts: 2127
Joined: Tue Nov 20, 2007 10:53 am

Re: How do I count cells?

Post by kingfisher »

A small macro should do it. It would be a matter of multiplying the number of columns by the number of rows. I don't recall any spreadsheet software which counts the number of cells selected.
Apache OpenOffice 4.1.12 on Linux
Post Reply