I am Still Lost on a Formula

Kenb

New Member
Joined
Nov 4, 2005
Messages
15
Not sure if I will ever get this: Here it goes...Is there a formula for doing this?? IF A10 is "A" add a count of +1 to total in C10. IF 0 (or blank) do nothing. Some have helped with VBA code that just really sends me for a ride. Thanks to you who have tried to help. Sorry I don't have your handles (names) handy. Sure wish I had more knowledge with XL but I AM trying hard!!

Ken
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
What's the current formula in cell C10?

You could change it to be:
=...current_formula...+IF(A10="A",1,0)
 
Upvote 0
Not making sense

Hi Ken,

you said:
IF A10 is "A" add a count of +1 to total in C10.

so, what does total in C10 mean exactly?
 
Upvote 0
Maybe...

=C10+IF(A10="A",1,0)

or

=C10+(A10="A")

Hope this helps!
 
Upvote 0
Dominic, you can't have a formula in C10 referring to C10.
 
Upvote 0
GlennUK said:
Dominic, you can't have a formula in C10 referring to C10.

I don't think the formula will be placed in C10. My understanding is that if A10 equals "A", 1 is to be added to the amount in C10, and the result returned in some other cell. Of course, I could be wrong... :)
 
Upvote 0
Ah yes, the syntax of the original request could be taken 2 ways ... you could be right.
 
Upvote 0
Please Continue to Help on this Formula

OK...Man just asking the question right is tough!!! I have a column A, in column A (Actually A10:A300) I will put a T for Tardy, an A for absent or I will just leave it blank. When I enter a T, I want column B to begin to tally up each time I enter a T. In column C I want to tally up each time I enter an A. I can do this and get a result of 1....at the FIRST time I make an entry. The problem is within minutes I will clear the contents of column A - this wipes out the value in column B. I need B and C to hold the value and the next time I enter an A I need column B to now show 2 (for 2 occasions of A being entered into cell A10. I sure hope ya'all can have patience with me, no doubt I am slow on this stuff.

I am counting each students (B10:B300)espisodes of Tardies in a column, & espisodes of Absensces in another column. Column A is where I enter either T, A, or leave blank. Total tardies and absences are NOT total for A10:300) But are for each row. Cell A1 will be T or A (or Blank, Cell B1 isstudent name, Cell C1 is tardies for student in this row, D1 is for absents of student in this row. If I clear contents of column A all other content in cells that related go away also. This is bad. I need the values in related cells to stay so I can add to them, and at the end of the month or quarter I will have a total number a student was absent and tardy.
 
Upvote 0
You can't do that with formulae, AND you need to think!

Hi Ken,

you can't do what you want with formulae.

Think about how Excel works ... it calculates totals and expressions based on current contents of cells. It doesn't "remember" values and increment them when you want ( not with formulae anyhow ). There are ways around this, but think about how dangerous your required solution is ... you want to show only the tally of tardies and absences for each student .. but if you make a mistake you will not be able to track back over you entries to find your error, because you tally will not be made up of entries, but of single numbers incremented somehow whenever you type into a cell. This method that you've requested is a very bad idea indeed. I recommend that you think about creating a master table with one row per student per month, with 31 columns for each day, and record each tardy and absence individually. You can do normal Excel summing and analysis ona table like that.

If you don't want to follow my recommendation, you are going to need a VBA routine, triggered by the sheet's Worksheet_Change event, which will increment tallies whenever you type an A or a T.

Good luck.
 
Upvote 0

Forum statistics

Threads
1,203,502
Messages
6,055,772
Members
444,822
Latest member
Hombre

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top