Dear All Exceliers,

I have some code which I have trouble getting to work. It is for finding the value of the rightmost cell of each row. The "dd" variable is a string that is outputting column ranges as expected, but once it is place in as argument in the INDEX formula, it doesnt work. Can any kind soul help me out a little. Your help is greatly appreciated. Thanks, Andy!

Private Sub Find_Latest()

Dim LastRow As Long, c As Range
Application.EnableEvents = False
LastRow = Cells(Cells.Rows.Count, "F").End(xlUp).Row
On Error Resume Next
For Each c In Range("G7:G" & LastRow)
Dim z As String

Dim x As Long
Dim y1, y2, dd1, dd2 As String
Dim dd As String

x = c.Row
y1 = c.Column + 1
y2 = c.Column + 11
dd1 = Cells(x, y1).Address(RowAbsolute:=False, ColumnAbsolute:=False)
dd2 = Cells(x, y2).Address(RowAbsolute:=False, ColumnAbsolute:=False)
dd = dd1 + ":" + dd2

c.Value = "=INDEX(dd,MATCH(REPT(""Z"",255), dd))"

'c.Value = dd

Next
On Error GoTo 0
Application.EnableEvents = True
End Sub