ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Loopy? (https://www.excelbanter.com/excel-worksheet-functions/65358-loopy.html)

AnthonyG

Loopy?
 
I have a constant value in A3
and wish to put values in A4
that will change.
I want A5 to total A3 and the values
in A4.
I can only get my formulas to add A3
and the new input value of A4.
How can I capture the running total so
A5 accumulates when I input new values
into A4 ?

Regards Ant.



Biff

Loopy?
 
See this:

http://mcgimpsey.com/excel/accumulator.html

Biff

"AnthonyG" wrote in message
...
I have a constant value in A3
and wish to put values in A4
that will change.
I want A5 to total A3 and the values
in A4.
I can only get my formulas to add A3
and the new input value of A4.
How can I capture the running total so
A5 accumulates when I input new values
into A4 ?

Regards Ant.





Don Guillett

Loopy?
 
Right click sheet tabview codeinsert thismodify to suitSAVE

Private Sub Worksheet_Change(ByVal Target As Range)
Application.EnableEvents = False
If Target.Address = "$A$4" And IsNumeric(Target) Then _
Range("a5").Value = range("a3")+ Range("a5") + Target
Application.EnableEvents = True
End Sub

--
Don Guillett
SalesAid Software

"AnthonyG" wrote in message
...
I have a constant value in A3
and wish to put values in A4
that will change.
I want A5 to total A3 and the values
in A4.
I can only get my formulas to add A3
and the new input value of A4.
How can I capture the running total so
A5 accumulates when I input new values
into A4 ?

Regards Ant.






All times are GMT +1. The time now is 04:10 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com