Range Selection

M

M@DG33K

Hi Again

I was tryin gto programatically select a range basis the current
position and a fixed reference

I'm using the following code snippet

Dim CurrentCell As String

CurrentCell = ActiveCell.Address

Range("b1:CurrentCell").Select

It gives an error 400 and exits

any ideas as to what am I doing wrong?

regs

Chirag
 
L

Leo Heuser

Hi again

Try
Range("b1:" & CurrentCell).Select

In
Range("b1:CurrentCell")
Excel will "see" CurrentCell as a
string of characters, not as a variable.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top