Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
This first inserts the new blank row below the ActiveCell and yjrm does the
pastes Sub Macro1() ActiveCell.Offset(1, 0).EntireRow.Insert n = ActiveCell.Row Set r1 = Range("B" & n & ":Q" & n) Set r2 = Range("B" & n + 1) r1.Copy r2 Set r3 = Range("F" & n & ":G" & n) Set r4 = Range("F" & n + 1) r3.Copy r4.PasteSpecial Paste:=xlPasteValues End Sub -- Gary''s Student - gsnu2007k " wrote: Hi, I am trying to create a macro that will copy the row (from B:Q) my active cell is in and paste the content into a newly inserted row below my active cell. Also, I would like it to copy the formulas that are in the row and paste them as formulas in the new row. Except for columns F and G I would prefer the formulas are pasted as values instead.Is this possible? I would appreciate your help as my knowledge in VB is very basic. Thanks! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Macro to copy and paste values (columns)I have a macro file built | Excel Programming | |||
copy multiple worksheets of a workbook, and paste onto a Word document ( either create new doc file or paste onto an existing file.) I need this done by VBA, Excel Macro | Excel Programming | |||
Copy and Paste macro needs to paste to a changing cell reference | Excel Programming | |||
how to count/sum by function/macro to get the number of record to do copy/paste in macro | Excel Programming | |||
Macro to Copy/Paste then Paste to Next Line | Excel Programming |