Automatically Moving from Cell to Cell when Entering Data

pmeghnathi

Board Regular
Joined
Mar 11, 2018
Messages
98
Office Version
  1. 2003 or older
Platform
  1. Windows
A1 cell value 12345678 (8 any character number) to auto move a2.than a2 any value ENTER hit key enter to move a2 cell continue this one by one 2 column

Move cursor
 
Still enter values via TAB instead of ENTER, but right click on your sheet, select "view code", and paste this:

Code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 2 Then Cells(Target.Row + 1, 1).Select
End Sub
 
Upvote 0

Excel Facts

Format cells as date
Select range and press Ctrl+Shift+3 to format cells as date. (Shift 3 is the # sign which sort of looks like a small calendar).
Still enter values via TAB instead of ENTER, but right click on your sheet, select "view code", and paste this:

Code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column = 2 Then Cells(Target.Row + 1, 1).Select
End Sub
i do this but a1 cell value typing and hit enter key not move cursor b1 cell. but b1 cell typing value and hit enter key to move cursor a2 is work. A to B not work . but B to A is work
 
Upvote 0
You said "I do this"... "typing and hit enter key".

You shouldn't be pressing the ENTER key at all. You should only be pressing the TAB key to confirm values when you're done typing them.

When you press the ENTER key to confirm a value, Excel will move to the next cell down. When you press TAB to confirm a value, Excel will move to the next cell to the right. The macro is there to move to column A in the next row down if you press tab after you enter a value into column B.
 
Upvote 0
You said "I do this"... "typing and hit enter key".

You shouldn't be pressing the ENTER key at all. You should only be pressing the TAB key to confirm values when you're done typing them.

When you press the ENTER key to confirm a value, Excel will move to the next cell down. When you press TAB to confirm a value, Excel will move to the next cell to the right. The macro is there to move to column A in the next row down if you press tab after you enter a value into column B.
I want only enter key not use tab key
 
Upvote 0
Same idea as before, just with different actions for whether you've edited column A or column B:

Code:
Private Sub Worksheet_Change(ByVal Target As Range)
    Select Case Target.Column
        Case 1
            Cells(Target.Row, 2).Select
        Case 2
            Cells(Target.Row + 1, 1).Select
    End Select
End Sub
 
Upvote 0
Solution

Forum statistics

Threads
1,223,958
Messages
6,175,629
Members
452,661
Latest member
Nonhle

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top