Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default How to add in increments for multiple cells

Hi, to keep this question simple.....what I'd like to be able to do is to
create a macro that will add an increment of 1 to the existing number in
multiple selected cells (example: if i have a2, a17, a20, a21, and a40
selected, I want to add 1 to their existing sum - none will have the same
resulting sum).

Thanks!
MaggieV
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,339
Default How to add in increments for multiple cells

Try:

I created a named range called "Increment" which holds value to be added.
Select cells to adjusted and call macro

Sub Add_Incr()
Dim incr as Double
incr = Range("Increment")
For Each cell In Selection
cell.Value = cell.Value + incr
Next
End Sub

HTH

"MaggieV" wrote:

Hi, to keep this question simple.....what I'd like to be able to do is to
create a macro that will add an increment of 1 to the existing number in
multiple selected cells (example: if i have a2, a17, a20, a21, and a40
selected, I want to add 1 to their existing sum - none will have the same
resulting sum).

Thanks!
MaggieV

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
need to paste link from 4 vertical cells to 4 horizontal cells? cioangel Excel Discussion (Misc queries) 6 June 8th 09 06:44 PM
Merge Cells Bagia Excel Discussion (Misc queries) 8 January 5th 07 09:18 PM
extend my formula with increments of 4 cells amoore Excel Worksheet Functions 5 April 27th 06 04:10 PM
Help adding text values Texas-DC_271 Excel Worksheet Functions 7 January 15th 05 11:14 PM
Convert data type of cells to Text,Number,Date and Time Kevin Excel Worksheet Functions 1 December 31st 04 12:57 PM


All times are GMT +1. The time now is 11:23 AM.

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

About Us

"It's about Microsoft Excel"