Moving within a range, using a macro!!

B

Bob Westaby

I have a macro that says, Range("B1").Select, now I want to move within a
range automatically,and I want to be able to exit by hitting the ESC button.
The spreadsheet looks like this:
A B C D
1 Beginning 10000 10000 10000
2 Today's
3 Total 10000 10000 10000
4 Sales

There are more lines to this, but this is the general idea, I would like to
move to the right and skip a line and move down to the next empty cell, or
exit.
 
D

Don Guillett

Why do you need to move to the cell? Selections are usually NOT necessary or
desirable. You do not even need to goto the sheet involved.
with sheets("yoursheet")
range("a1")="hi"
range("b1")=1*23
'etc.
end with
 

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