How to go to a cell after exiting another distant cell?

W

Wind54Surfer

I managed to make the link work, but it is not what I am looking for.

I need to be able to jump from 1 cell to another one , and I would like to
do it with code.

Can someone show me an example? Please

Thanks again,
Emilio
 
G

Gord Dibben

Wind

There are a couple of methods there. Did neither one work and why not?

A third method is by code if you want to use it.

'moves from C2 through E5 at entry
Private Sub Worksheet_Change(ByVal Target As Range)
Select Case Target.Address
Case "$C$2"
Range("C5").Select
Case "$C$5"
Range("E2").Select
Case "$E$2"
Range("E5").Select
End Select
End Sub

Right-click on your sheet tab and "View Code". Copy/paste in there.


Gord Dibben Excel MVP
 
G

Gord Dibben

Whoops. You did say the link didn't work. I mistook that for methods didn't
work. Sorry about that.

Anyway, now you have code.

Gord
 
W

Wind54Surfer

Thanks, but my knowledge of code in Access doesn't help me here, since there
are no events to trigger the code, can't figure out how to make it work.

Can you please expand on how to get the code to work when exiting say cell C2?

Thanks for any help,
Emilio
 
W

Wind54Surfer

How stupid of me

Worksheet is not the same as Workbook

I get it now

Thanks a lot!

Emilio
 

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