![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: Apr 2002
Posts: 3
|
Hi,
I am trying to get Excel to automatically go to the beginning cell of the next row. I have a worksheet that is 5 columns wide. When the last column e.g. E10 has data in it, I want to to automatically go to A11 for data input. Any help would be great. thanks [ This Message was edited by: ozone64 on 2002-04-22 17:25 ] |
|
|
|
|
|
#2 | |
|
MrExcel MVP
Join Date: Mar 2002
Location: Chicago, IL USA
Posts: 2,042
|
Quote:
In the code module for the worksheet you are working on, put the following in the worksheet_change event...... Private Sub Worksheet_Change(ByVal Target As Excel.Range) If Target.Column <= 4 Then Cells(Target.Row, Target.Column + 1).Select If Target.Column = 5 Then Cells(Target.Row + 1, 1).Select End Sub This moves one cell to the right for the first 4 cols, then 1 row down and to col A when you enter in col E. In all other columns, it is whatever Excel is set to after a change. Bye, Jay |
|
|
|
|
|
|
#3 | |
|
MrExcel MVP
Join Date: Mar 2002
Location: Michigan USA
Posts: 11,452
|
Quote:
I realize that you asked for amacro solution, and Jay has provided one above. There ias a non-macro solution that also might be of interest here ... If you data entry cells are unlocked, and the worksheet is protected, then using the TAB key, after you TAB into E10, it will automatically into A11. HTH
__________________
Regards! Yogi Anand, D.Eng, P.E. Energy Efficient Building Network LLC www.energyefficientbuild.com |
|
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|