# OpenOffice Calc

**URL:** <https://boards.straightdope.com/t/openoffice-calc/533033>\
**Category:** Factual Questions\
**Created:** [March 19, 2010, 4:58pm UTC](https://boards.straightdope.com/t/openoffice-calc/533033 "2010-03-19T16:58:19Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![NOLA\_Cajun](https://avatars.discourse-cdn.com/v4/letter/n/ea666f/32.png) [@NOLA\_Cajun](https://boards.straightdope.com/u/NOLA_Cajun)\
**Post date:** [March 19, 2010, 4:58pm UTC](https://boards.straightdope.com/t/openoffice-calc/533033/1 "2010-03-19T16:58:19Z")

</div>

I have a spreadsheet in calc that I’m trying to figure out a formula for. I use the spreadsheet for invoice billing puproses. It’s a simple spreadsheet that has 5 columns. date, company, po#, phone no., amount to be billed. At the bottom of the last column (amount to be billed) I have 3 fields to the left of that column, TOTAL RUNS (how many service calls I performed), LESS CASH received and TOTAL AMOUNT I expect to be paid. For total amount I expect to be paid I have the formula: =SUM(F2:F30)-F33 (f2:f3 being the total of all my invoices and -f33 which is the less cash received). And that works fine. What would be nice is for it to automatically input the total service calls performed in the TOTAL RUNS field. For instance this week I have a total of 22 calls so far and each time I add a call I would like that number to increase. It’s certainly easy enough for me to input the number but I was just trying to figure out of there is a formula that would do it if there is any formula that can count the rows (or rows in column F that has the dollar amount) that are populated with information, each row representing 1 service call. Something like f2 through f30 have 22 of them populated for a total of 22 total runs. Hope that all makes sense. Thanks in advance for any help.

---

<div class="post-metadata">

**Author:** ![control-z](https://avatars.discourse-cdn.com/v4/letter/c/eada6e/32.png) [@control-z](https://boards.straightdope.com/u/control-z)\
**Post date:** [March 19, 2010, 6:06pm UTC](https://boards.straightdope.com/t/openoffice-calc/533033/2 "2010-03-19T18:06:16Z")

</div>

So you want a function to count the rows? If so this should do it:

=COUNT(A1:A100) - counts how many cells in range A1 to A100 contains numbers  
=COUNTA(A1:A100) - counts how many cells in range A1 to A100 contains any values (numbers, letters, other characters,…)  
=COUNTBLANK(A1:A100) - counts how many blank cells is in range A1 to A100  
=COUNTIF(A1:A100;B1) - counts how many cells in range A1 to A100 contains the same value as B1  
Put theese functions in any cell except A1 to A100 (and B1 for countif) in this case.  
Insert your own range of data instead of A1 to A100 of course.

---

<div class="post-metadata">

**Author:** ![NOLA\_Cajun](https://avatars.discourse-cdn.com/v4/letter/n/ea666f/32.png) [@NOLA\_Cajun](https://boards.straightdope.com/u/NOLA_Cajun)\
**Post date:** [March 19, 2010, 6:43pm UTC](https://boards.straightdope.com/t/openoffice-calc/533033/3 "2010-03-19T18:43:34Z")

</div>

Thank you so much control-z. That was perfect. Mods can close this thread. Asked & Answered. And give control-z a raise, promotion, and kudos!!

---

<div class="post-metadata">

**Author:** ![control-z](https://avatars.discourse-cdn.com/v4/letter/c/eada6e/32.png) [@control-z](https://boards.straightdope.com/u/control-z)\
**Post date:** [March 19, 2010, 6:57pm UTC](https://boards.straightdope.com/t/openoffice-calc/533033/4 "2010-03-19T18:57:12Z")

</div>

You’re welcome. I just Googled it. 😉

---

<div class="post-metadata">

**Author:** ![NOLA\_Cajun](https://avatars.discourse-cdn.com/v4/letter/n/ea666f/32.png) [@NOLA\_Cajun](https://boards.straightdope.com/u/NOLA_Cajun)\
**Post date:** [March 19, 2010, 7:05pm UTC](https://boards.straightdope.com/t/openoffice-calc/533033/5 "2010-03-19T19:05:47Z")

</div>

I would have tried that but I had no idea what to google. COUNT didn’t even occur to me.

---

<div class="post-metadata">

**Author:** ![control-z](https://avatars.discourse-cdn.com/v4/letter/c/eada6e/32.png) [@control-z](https://boards.straightdope.com/u/control-z)\
**Post date:** [March 19, 2010, 7:12pm UTC](https://boards.straightdope.com/t/openoffice-calc/533033/6 "2010-03-19T19:12:38Z")

</div>

Googling seems to be a skill. I Googled this:

openoffice calc “row count”

The first result contained the answer.

There, I’ve taught a man to fish. 😃

---

<div class="post-metadata">

**Author:** ![Voyager](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/voyager/32/133_2.png) [@Voyager](https://boards.straightdope.com/u/Voyager)\
**Post date:** [March 19, 2010, 7:26pm UTC](https://boards.straightdope.com/t/openoffice-calc/533033/7 "2010-03-19T19:26:13Z")

</div>

I’ve used this trick - works like a charm, so I have nothing to add.
