Formula to add a new data entry to an existing number to get a new sum total

Cquake

Board Regular
Joined
Dec 12, 2017
Messages
57
Office Version
  1. 2016
Platform
  1. Windows
I have looked around and can't seem to find the correct answer for this. Here is what I am trying to do. For help purposes I have created a chart with the following headings. I would like to be able to enter a production number in the today column that would automatically add that entry to the TOTAL column to get a new number and then clear out the TODAY column to enable to me to enter a new entry later to once again add to the TOTAL column. Any help would be greatly appreciated. The headings would be A1:D1. The TOTAL columns would then show 56, 54, 78, 74 after those entries.

NAMEDAYSTOTALTODAY
John53125
Henry42727
Tom85523
Barbara64133
 

Excel Facts

Why are there 1,048,576 rows in Excel?
The Excel team increased the size of the grid in 2007. There are 2^20 rows and 2^14 columns for a total of 17 billion cells.
You cannot do that with a formula, it would need to be VBA, is that ok?
 
Upvote 0
Ok, how about
VBA Code:
Private Sub Worksheet_Change(ByVal Target As Range)
   If Target.CountLarge > 1 Then Exit Sub
   If Target.Column = 4 Then
      Application.EnableEvents = False
      Target.Offset(, -1).Value = Target.Offset(, -1).Value + Target.Value
      Target = ""
   End If
   Application.EnableEvents = True
End Sub
This needs to go in the relevant sheet module & will update col C whenever you enter a value in col D.
This only works if you change the cells in col D individually.
 
Upvote 0
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,214,522
Messages
6,120,022
Members
448,939
Latest member
Leon Leenders

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