[Copying from Excel: portable formula to reference data on relative worksheet.]
Create the following macro:
Function SHEET_OFFSET(Offset, Ref)
' Returns cell contents at Ref, in sheet Offset
Application.Volatile
With Application.Caller.Parent
SHEET_OFFSET = .Parent.Sheets(.Index + Offset) _
.Range(Ref.Address).Value
End With
End Function
See How do I add VBA in MS Office?
for general information on using macros.
Then, if you want the references on Sheet1 to look like this:
A B C
1 =Sheet2!G17 =Sheet2!M42 =Sheet2!Q95 ...
2 =Sheet3!G17 =Sheet3!M42 =Sheet3!Q95 ...
︙ ︙ ︙
set A1 to SHEET_OFFSET(ROW(), $G$17), etc.
The first argument is the sheet number, relative to the current one,
and the second argument is the cell reference.