activecell.formulaR1C1 = "='i'!R10C6" 'i is a variable

M

Mahi

i cant get the following line working in my VBA programme
please hep me
activecell.formulaR1C1 = "='i'!R10C6"
where i is a variable referencing the sheet index number of all previous
sheets
thank you
Mahi
 
D

Dave Peterson

I don't understand what i represents ("the sheet index number of all previous
sheets" confuses me).

But maybe:

dim i as long
activecell.formular1c1 = "'" & worksheets(i).name & "'!r10c6"
 
Top