Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel Tabbing and Entering 2

Status
Not open for further replies.

Leslie67

Programmer
Jul 23, 2002
42
US
I have a worksheet where I've got the tab to work as I want - only going to the cells that need information input into them.

Is there a way to make the "Enter" key follow the same tabbing?

The tabbing moves from left to right and then down a row when it gets to the end of the sheet. When I hit the "Enter" key, it goes down to the next row, not to the cell to the right which is where I want it to go.

Any suggestions?
 
You can do it with VBA. First, from excel, unlock cells you want to enter data (Format>Cells.. ant >protection tab). Next protect sheet (Tools>Protection). The user will be able to enter only unlocked cells, but still can select any.
Now VBA: Right-click the page tab and select "View code". Add the code below:
[tt]Private Sub Worksheet_Activate()
me.EnableSelection=xlUnlockedCells
End Sub[/tt]

combo
 
This is for Excel 97. (2K/XP might be different):

In addition to combo's code, do the following:
Code:
  Tools/Options... Edit tab
then check the box that says "Move selection after Enter" and choose the Direction "Right"
 
And this should make the "Enter" key follow the same tabbing path as when I hit the "Tab" key?

Cause when I use the "Enter" key it's not.

When I hit the Tab key, it moves from
b5 to j5
then down to b6 and L6
and down to c7.

When I hit the Enter key, it moves from
b5
down to b6
down to c7
and then on to another section...
 
Thank you both: combo for the code and Zathras for the &quot;moving to the right&quot; tool option <g>.

One more question, though...

When I'm using the Enter key, it doesn't go to the next row down when it hits the end of the page.

Is there a way to force it to do this rather than running off the side of the page?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top