Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
baggie
 
Posts: n/a
Default adding to an exisitng number

with a pre-existing number in a cell, hoew do I add another number to it?
  #2   Report Post  
Dan Chupinsky
 
Posts: n/a
Default

If your pre-existing number is in A1 and you wish to add the number in B1 to
it, put you cursor in B1, use EditCopy, put your cursor in A1, use
EditPaste Special and choose Add, and click OK

Dan

"baggie" wrote in message
...
with a pre-existing number in a cell, hoew do I add another number to it?



  #3   Report Post  
Don Guillett
 
Posts: n/a
Default

right click sheet tabview codeinsert thismodify to suitSAVE.

Dim oldvalue As Double
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
If Target.Address = "$A$5" Then
On Error GoTo fixit
Application.EnableEvents = False
If Target.Value = 0 Then oldvalue = 0
Target.Value = 1 * Target.Value + oldvalue
oldvalue = Target.Value
fixit:
Application.EnableEvents = True
End If
End Sub

--
Don Guillett
SalesAid Software

"baggie" wrote in message
...
with a pre-existing number in a cell, hoew do I add another number to it?



  #4   Report Post  
Jim May
 
Posts: n/a
Default

Don,
If in cell A1 (value to be changed) = 4 and if in cell A5 OP enters 9
I interpret request that he wants A1 to become 13.
If so, don't we need to assign oldvalue = 4 before hand?
Appreciate your input..
Jim

"Don Guillett" wrote in message
...
right click sheet tabview codeinsert thismodify to suitSAVE.

Dim oldvalue As Double
Private Sub Worksheet_Change(ByVal Target As Excel.Range)
If Target.Address = "$A$5" Then
On Error GoTo fixit
Application.EnableEvents = False
If Target.Value = 0 Then oldvalue = 0
Target.Value = 1 * Target.Value + oldvalue
oldvalue = Target.Value
fixit:
Application.EnableEvents = True
End If
End Sub

--
Don Guillett
SalesAid Software

"baggie" wrote in message
...
with a pre-existing number in a cell, hoew do I add another number to it?





Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
adding a zero in front of number Pinky Excel Discussion (Misc queries) 3 April 7th 05 09:05 PM
adding to a number containing text R D S Excel Discussion (Misc queries) 4 January 21st 05 03:55 AM
Adding + in front of a number Ted Metro Excel Discussion (Misc queries) 3 December 29th 04 10:45 PM
Adding a number to a date as workdays Chris Maximus Excel Worksheet Functions 6 December 8th 04 08:48 PM
GET.CELL Biff Excel Worksheet Functions 2 November 24th 04 07:16 PM


All times are GMT +1. The time now is 09:36 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"