Excel Enter Key Sequence?

D

Dono2008

Hi,

Have a bit of a problem that i'm hoping someone here can help me solve.

Basically in a spreadsheet, i need the enter key to shift the selection to
the right for 3 columns when pressed, and then after the Third time i push
the enter key i want it to set the selection to the first column again, but
on the row below,

For example,

A1 (ENTER) B1 (ENTER) C1 (ENTER) A2 (ENTER) B2.........ETC

If anyone could help me out i would be extremely greatful.

Thanks in advance,

(e-mail address removed)
 
D

Don Guillett

Right click sheet tab>view code>copy/paste this.

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Count > 1 Then Exit Sub
Select Case Target.Column
Case Is < 4: Target.Offset(, 1).Select
Case 4: Target.Offset(1, -3).Select
Case Else
End Select
End Sub
 
D

Don Guillett

I forgot to mention that this has the added advantage of it moves the cursor
when you enter something in the appropriate cell and then hit enter. Doesn't
work on just enter. For a blank you would have to hit the space bar first.
 
J

Joel

A worksheet change function will work

Private Sub worksheet_change(ByVal target As Range)

Select Case target.Column
Case 1, 2
target.Offset(0, 1).Select
Case 3
Range("A" & (target.Row + 1)).Select
End Select
End Sub
 
G

Gord Dibben

Start in A1 then hit Tab key to move to B1 then C1.
Hit ENTER key to go back to A2

Make sure ENTER key is set to move down when hit.


Gord Dibben MS Excel MVP
 

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