updating a cell value
What is the syntax used to update a cell value (number) by adding a value
from another cell. For example, I want cell B1 to return the value of B1 plus the inputed value of A1. In other words, I want B1 to continue to incease by the amount that I put into A1. I am using Excel 2003. |
updating a cell value
Right click on your worksheet tab, select View Code and paste the following
into the code module Private Sub Worksheet_Change(ByVal Target As Range) Application.EnableEvents = False If Target = Cells(1, 1) Then _ Cells(1, 2).Value = Cells(1, 2).Value + Target.Value Application.EnableEvents = True End Sub "Ray H." wrote: What is the syntax used to update a cell value (number) by adding a value from another cell. For example, I want cell B1 to return the value of B1 plus the inputed value of A1. In other words, I want B1 to continue to incease by the amount that I put into A1. I am using Excel 2003. |
updating a cell value
See this:
http://mcgimpsey.com/excel/accumulator.html Biff "Ray H." <Ray wrote in message ... What is the syntax used to update a cell value (number) by adding a value from another cell. For example, I want cell B1 to return the value of B1 plus the inputed value of A1. In other words, I want B1 to continue to incease by the amount that I put into A1. I am using Excel 2003. |
All times are GMT +1. The time now is 11:32 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com