Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 280
Default pls help with macro

Option Explicit

Sub Main()
Dim rSourceRange As Range
Dim rTargetRange As Range
Set rSourceRange = _
Worksheets("Sheet1").Range("B1:B10")
Set rTargetRange = _
Worksheets("Sheet2").Range("B1:B10")

rTargetRange.Value = 0.01
rSourceRange.Copy
rTargetRange.PasteSpecial _
Paste:=xlPasteAll, _
Operation:=xlAdd, _
SkipBlanks:=False, _
Transpose:=False
Application.CutCopyMode = False
Set rSourceRange = Nothing
Set rTargetRange = Nothing
End Sub


--
Bob Kilmer


"Sam" wrote in message
om...
INCREMENTAL MACRO
this is my data
COLUMN COLUMN
A B
------- ----------------
A 1%
B 2%
C 4%
D 2%
E 1%
F 2%
G 4%
H 7%
I 1%
J 2%

i want to write a macro that will add 0.01 to CELL B1 AND COPY THIS
DATA TO SHEET 2 , THEN RESET CELLB1 BACK TO ORIGINAL VALUE AND THEN
ADD 0.01 TO CELL B2 AND DO THE SAME AS ABOVE AND GO ON UNTIL ROW 10
......

IN THIS WAY I NEED TO SEE ON SHEET 2 - THE NEW DATA WITH INCREMENTS
OFF 0.01 MADE TO ALL THE VALUES IN COLUMN B ....

pls help


sam



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
Macro recorded... tabs & file names changed, macro hangs Steve Excel Worksheet Functions 3 October 30th 09 11:41 AM
need help to update macro to office 2007 macro enabled workbook jatman Excel Discussion (Misc queries) 1 December 14th 07 01:57 PM
Macro Help Needed - Excel 2007 - Print Macro with Auto Sort Gavin Excel Worksheet Functions 0 May 17th 07 01:20 PM
Macro needed to Paste Values and prevent Macro operation thunderfoot Excel Discussion (Misc queries) 1 June 11th 05 12:44 AM
Macro needed to Paste Values and prevent Macro operation thunderfoot Excel Discussion (Misc queries) 0 June 10th 05 03:38 PM


All times are GMT +1. The time now is 03:47 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"