![]() |
|
#1
|
||||
|
||||
|
Hi. My macro creation level is limited to recording. I created a code by recording the steps in copying the value of A2 then pasted it in B2. When I selected A16 then ran the macro, the value in A16 was pasted in B2. It should be copied to B16 which is the adjacent cell of A16. How do I edit the line:
Range ("B2").Select? Code:
Sub Copy()
Selection.Copy
Range("B2").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
End Sub
|
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
How to paste the value of a selected cell to another sheet?
|
Learner7 | Excel Programming | 3 | 06-30-2019 10:35 PM |
Fill blank cell with value from adjacent cell
|
kevinbradley57 | Excel Programming | 2 | 04-17-2018 08:40 AM |
| IF adjacent cell empty Copy from Other Column | ChrisOK | Excel Programming | 8 | 03-08-2018 09:17 PM |
| Increase number in cell, based on value in adjacent cell | scottyb | Excel | 3 | 02-02-2017 03:51 AM |
How to conditionally format cells in Col. A if it matches adjacent cell in Col. B?
|
alshcover | Excel | 2 | 06-03-2014 12:50 PM |