Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Stuart Grant
 
Posts: n/a
Default ActiveCell.Copy Range("R3C27")

I thought it should be easy. I'm writing a macro. The first part leads the
Active Cell to a location depending on the value of various (declared)
variables. I then want to copy the value in this cell to another cell on
the same Worksheet. The line in the title doesn't work nor do nor do
various alternatives involving Paste or Select. I always get the dreaded
Error 1004 - and the Help button is totally unhelpful.

Does anyone know how to copy the contents of the Activecell to another Cell
on the same Worksheet?
Stuart


  #2   Report Post  
Dave Peterson
 
Posts: n/a
Default

activecell.copy _
destination:=cells(3,27)

or
activecell.copy _
destination:=range("AA3")

(if I did the translation correctly.)

Stuart Grant wrote:

I thought it should be easy. I'm writing a macro. The first part leads the
Active Cell to a location depending on the value of various (declared)
variables. I then want to copy the value in this cell to another cell on
the same Worksheet. The line in the title doesn't work nor do nor do
various alternatives involving Paste or Select. I always get the dreaded
Error 1004 - and the Help button is totally unhelpful.

Does anyone know how to copy the contents of the Activecell to another Cell
on the same Worksheet?
Stuart


--

Dave Peterson
  #3   Report Post  
Stuart Grant
 
Posts: n/a
Default

Dave: Thanks very much for your prompt help.
activecell.copy destination:=range("R3C27") doesn't work.
activecell.copy destination:=range("AA3") does, even though the worksheet is
on R1C1 basis.

Next problem I found was that it copied, but to the wrong worksheet ! The
macro was written in the VBA of another sheet. I moved it. That didn't
work. I deleted it and rewrote it in a module.

Now everything works. You live and learn. Thanks again.
Stuart


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



All times are GMT +1. The time now is 11:22 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"