View Single Post
  #5   Report Post  
Nick Hodge
 
Posts: n/a
Default how to include a cell reference that is contained in a cell withi.

I usually look from the known bottom cell up, so in your case I would use

Dim lLastRow as Long
lLastRow=Range("A65536").End(xlUp).Row

You can then use the lLastRow variable in your code, e.g

Range("A1").Copy Destination:= Range("A"&lLastRow)

--
HTH
Nick Hodge
Microsoft MVP - Excel
Southampton, England
www.nickhodge.co.uk
HIS


"dutchinny" wrote in message
...
cell named 'gohere' contains a cell reference created by concatenation:
="$A$"&D15
(where d15 contains the count of non-blank cells.) so i end up with e.g.
$a$7. my question is how to reference the cell named 'gohere' in a macro
that will place me in $a$7. i'm only a beginning macro-ist with no vb
experience......

my ultimate purpose is to paste content from sheet 1 to the next available
cell in sheet 2

i've tried to apply similar scenarios that i found on the forum to my
situation but haven't been very successful.

thank you for any advice.