a1+a2=a3 How can I change a2,keep old a2 value & increase a3

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I want to use less columns as possible. I want others to be able to change
one column while previous values are added to increase a3
 
This example uses only two cells: A1 & A2

Insert the following code in the wroksheet code area:

Private Sub Worksheet_Change(ByVal Target As Range)
If Intersect(Target, Range("A1")) Is Nothing Then Exit Sub
Application.EnableEvents = False
Range("A2").Value = Range("A2").Value + Range("A1").Value
Application.EnableEvents = True
End Sub


Whenever a value is entered in A1, its added into A2
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top