#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8
Default Refer to ActiveCell

I want a given cell eg z100 to constantly - or at each recalculation - to
hold the contents - or reference - of ActiveCell (so a text box can highlight
it.). My code does it but only once at each run of the module, then it sticks
or throws an error.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 143
Default Refer to ActiveCell

address of active cell at calc: =CELL("address")

contents: =INDIRECT(CELL("address"))


"ChrisR" wrote in message
...
|I want a given cell eg z100 to constantly - or at each recalculation - to
| hold the contents - or reference - of ActiveCell (so a text box can
highlight
| it.). My code does it but only once at each run of the module, then it
sticks
| or throws an error.

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default Refer to ActiveCell

And the code is..............?


Gord Dibben MS Excel MVP

On Thu, 24 Sep 2009 09:19:06 -0700, ChrisR
wrote:

I want a given cell eg z100 to constantly - or at each recalculation - to
hold the contents - or reference - of ActiveCell (so a text box can highlight
it.). My code does it but only once at each run of the module, then it sticks
or throws an error.


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8
Default Refer to ActiveCell

Homey suggested - I think -

Sub ActiveCell()
'
' ActiveCell Macro
' Macro recorded 28/09/2009 by Sheffield City Council
'

address of active cell at calc: =CELL("address")

contents: =INDIRECT(CELL("address"))

End Sub


But as a Macro this doesn't do anything except generate an error - "Compile
error Syntax error". I want it to paste the contents or reference of
ActiveCell into Z100, whenever I recalc (or when I run a Macro?)

Sorry to be naiive.

Chris

"Gord Dibben" wrote:

And the code is..............?


Gord Dibben MS Excel MVP

On Thu, 24 Sep 2009 09:19:06 -0700, ChrisR
wrote:

I want a given cell eg z100 to constantly - or at each recalculation - to
hold the contents - or reference - of ActiveCell (so a text box can highlight
it.). My code does it but only once at each run of the module, then it sticks
or throws an error.



  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default Refer to ActiveCell

If all you want is Z100 to return the activecell contents

Sub test()
Range("Z100) = ActiveCell.Value
End Sub


Gord


On Mon, 28 Sep 2009 10:04:01 -0700, ChrisR
wrote:

Homey suggested - I think -

Sub ActiveCell()
'
' ActiveCell Macro
' Macro recorded 28/09/2009 by Sheffield City Council
'

address of active cell at calc: =CELL("address")

contents: =INDIRECT(CELL("address"))

End Sub


But as a Macro this doesn't do anything except generate an error - "Compile
error Syntax error". I want it to paste the contents or reference of
ActiveCell into Z100, whenever I recalc (or when I run a Macro?)

Sorry to be naiive.

Chris

"Gord Dibben" wrote:

And the code is..............?


Gord Dibben MS Excel MVP

On Thu, 24 Sep 2009 09:19:06 -0700, ChrisR
wrote:

I want a given cell eg z100 to constantly - or at each recalculation - to
hold the contents - or reference - of ActiveCell (so a text box can highlight
it.). My code does it but only once at each run of the module, then it sticks
or throws an error.






  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8
Default Refer to ActiveCell

Thanks a million. That does it.

Chris

"Gord Dibben" wrote:

If all you want is Z100 to return the activecell contents

Sub test()
Range("Z100) = ActiveCell.Value
End Sub


Gord


On Mon, 28 Sep 2009 10:04:01 -0700, ChrisR
wrote:

Homey suggested - I think -

Sub ActiveCell()
'
' ActiveCell Macro
' Macro recorded 28/09/2009 by Sheffield City Council
'

address of active cell at calc: =CELL("address")

contents: =INDIRECT(CELL("address"))

End Sub


But as a Macro this doesn't do anything except generate an error - "Compile
error Syntax error". I want it to paste the contents or reference of
ActiveCell into Z100, whenever I recalc (or when I run a Macro?)

Sorry to be naiive.

Chris

"Gord Dibben" wrote:

And the code is..............?


Gord Dibben MS Excel MVP

On Thu, 24 Sep 2009 09:19:06 -0700, ChrisR
wrote:

I want a given cell eg z100 to constantly - or at each recalculation - to
hold the contents - or reference - of ActiveCell (so a text box can highlight
it.). My code does it but only once at each run of the module, then it sticks
or throws an error.




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
How do I use the .Cells property to refer to ActiveCell? Caeres Excel Discussion (Misc queries) 9 October 7th 08 02:56 PM
ACTIVECELL LOCATION kt(uk) Excel Discussion (Misc queries) 2 September 12th 08 01:03 PM
How to use ActiveCell to mean a particular cell? Jo[_2_] Excel Worksheet Functions 3 October 4th 07 09:38 PM
If activecell.column = variable then activecell,offset (0,1) Battykoda via OfficeKB.com Excel Discussion (Misc queries) 1 October 2nd 07 08:05 PM
highlight activecell flow23 Excel Discussion (Misc queries) 10 February 21st 06 12:01 PM


All times are GMT +1. The time now is 05:18 AM.

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"