PC Review


Reply
Thread Tools Rate Thread

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

 
 
Mahi
Guest
Posts: n/a
 
      21st Dec 2008
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
 
Reply With Quote
 
 
 
 
Mike
Guest
Posts: n/a
 
      21st Dec 2008
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

 
Reply With Quote
 
Dave Peterson
Guest
Posts: n/a
 
      21st Dec 2008
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 With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
ActiveCell.FormulaR1C1 = "=SUM(R[-tellerteller]C:R[-1]C)" Jack Sons Microsoft Excel Misc 5 29th Sep 2009 09:58 PM
.FormulaR1C1="abc" works, .Text="abc" doesn't. WHAT the? baobob@my-deja.com Microsoft Excel Programming 5 22nd Aug 2008 10:51 PM
Substitute variable in a VBA ActiveCell.FormulaR1C1 =?Utf-8?B?Um9Cbw==?= Microsoft Access VBA Modules 1 30th Jul 2007 12:42 PM
ActiveCell.FormulaR1C1 = "=IF(c4:c4<='Title Page'!$B$19,1,0)" ?? HELP!!! harteorama@googlemail.com Microsoft Excel Programming 4 29th Dec 2006 11:35 AM
ActiveCell.FormulaR1C1 = "=RC[-4]-RC[-2]" Jordi Microsoft Excel Programming 4 12th Nov 2003 01:26 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 10:55 PM.