Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
im trying to copy formulas from cells h,i, and j in row 2 to
the same cells in rows 52,102,152,202,252,302,etc.... up to row 49902 i thought a macro could do the trick but im having a hard time with the language any help or ideas would be greatly appreciated thank you brock spokane, wa |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Sub thishere()
hForm = Range("H2").Formula iForm = Range("A2").Formula jForm = Range("J2").Formula For i = 52 To 49902 Step 50 Cells(i, 8).Formula = hForm Cells(i, 9).Formula = iForm Cells(i, 10).Formula = jForm Next i End Sub BROCK8292 wrote: im trying to copy formulas from cells h,i, and j in row 2 to the same cells in rows 52,102,152,202,252,302,etc.... up to row 49902 i thought a macro could do the trick but im having a hard time with the language any help or ideas would be greatly appreciated thank you brock spokane, wa |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
try testing this and then just change the step 3 to whatever is desired such
as 52 Sub copymodrows() For i = 1 To 12 Step 3 Range("h1").Resize(, 3).Copy Cells(i, "h") Next End Sub -- Don Guillett Microsoft MVP Excel SalesAid Software "BROCK8292" wrote in message ... im trying to copy formulas from cells h,i, and j in row 2 to the same cells in rows 52,102,152,202,252,302,etc.... up to row 49902 i thought a macro could do the trick but im having a hard time with the language any help or ideas would be greatly appreciated thank you brock spokane, wa |
#5
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Hi,
Try this: Sub cpyr() Range("H2:J2").Select Selection.Copy For i = 52 To 49902 Step 50 Range("H" & Trim(Str(i))).Select ActiveSheet.Paste Next i End Sub -- Farhad Hodjat "BROCK8292" wrote: im trying to copy formulas from cells h,i, and j in row 2 to the same cells in rows 52,102,152,202,252,302,etc.... up to row 49902 i thought a macro could do the trick but im having a hard time with the language any help or ideas would be greatly appreciated thank you brock spokane, wa |
#6
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
thank you all for ur help
"Don Guillett" wrote: You will also want to change the 12 to whatever desired. Sub copymodrows() maybe use a variable to determine the last row lr-cells(rows.count,"h").end(xlup).row for i= 1 to lr step 52 For i = 1 To 12 Step 3 Range("h1").Resize(, 3).Copy Cells(i, "h") Next End Sub -- Don Guillett Microsoft MVP Excel SalesAid Software "Don Guillett" wrote in message ... try testing this and then just change the step 3 to whatever is desired such as 52 Sub copymodrows() For i = 1 To 12 Step 3 Range("h1").Resize(, 3).Copy Cells(i, "h") Next End Sub -- Don Guillett Microsoft MVP Excel SalesAid Software "BROCK8292" wrote in message ... im trying to copy formulas from cells h,i, and j in row 2 to the same cells in rows 52,102,152,202,252,302,etc.... up to row 49902 i thought a macro could do the trick but im having a hard time with the language any help or ideas would be greatly appreciated thank you brock spokane, wa |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How to copy the same formulas in a spreadsheet -Macro? | Excel Worksheet Functions | |||
Loop thru rows to copy to another excel spreadsheet | Excel Worksheet Functions | |||
Create Macro to Copy Data from one spreadsheet to another | Excel Discussion (Misc queries) | |||
Macro to copy cells to rows below | Excel Discussion (Misc queries) | |||
copy qualifying rows to another spreadsheet | Excel Worksheet Functions |