Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default activecell.formulaR1C1 = "='i'!R10C6" 'i is a variable

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
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,101
Default activecell.formulaR1C1 = "='i'!R10C6" 'i is a variable

ActiveCell.FormulaR1C1 = "='" & i & "'!R10C6"

"Mahi" wrote:

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

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default activecell.formulaR1C1 = "='i'!R10C6" 'i is a variable

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"



Mahi wrote:

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


--

Dave Peterson
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
ActiveCell.FormulaR1C1 = "=SUM(R[-tellerteller]C:R[-1]C)" Jack Sons Excel Discussion (Misc queries) 5 September 29th 09 09:58 PM
Replace(ActiveCell.Formula, "Round(","") not working as expected Dennis Excel Programming 3 May 16th 07 04:49 PM
ActiveCell.FormulaR1C1 = "=IF(c4:c4<='Title Page'!$B$19,1,0)" ?? HELP!!! [email protected] Excel Programming 4 December 29th 06 11:35 AM
use variable in Workbooks("book1").Worksheets("sheet1").Range("a1" Luc[_3_] Excel Programming 2 September 28th 05 08:37 PM
ActiveCell.FormulaR1C1 = "=RC[-4]-RC[-2]" Jordi Excel Programming 5 November 13th 03 12:21 AM


All times are GMT +1. The time now is 01:21 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"