Locating a cell within a macro

R

Ron (Bismark)

I have a lookup which gives me a cell ref in terms of R1C1 into cell A2
On the same sheet I have a value that I want to copy from Cell B2 into the
cell referenced to in A2.

I have a very basic knowledge of macros and not sure if this is possible.

Can anyone help?

thanks,

Ron.
 
M

Martin Fishlock

Ron,

The macro is as below. The tricky bit is to conver the R1C1 style reference
to A1 style:

Sub IndirectCopy()
Const cCellValue As String = "B2"
Const cCellIndirect As String = "A1"
Dim sCell As String
sCell = Application.ConvertFormula(Range(cCellIndirect), _
xlR1C1, xlA1)
Range(sCell).Value = Range(cCellValue).Value
End Sub
 
Top