Shift + Tab help

paveitcans

New Member
Joined
Dec 22, 2004
Messages
26
Good Morning, I have the code below in a worksheet to set the tab order. What I'm trying to do is enable it to use the Shift + Tab to "back up" in the sheet. Has anyone had any luck with this? Any help would be greatly appreciated.


Private Sub Worksheet_SelectionChange(ByVal Target As Excel.Range)
Select Case lastcell
Case "a1"
Range("e2").Select
lastcell = "e2"
Case "e2"
Range("e4").Select
lastcell = "e4"
Case "e4"
Range("e6").Select
lastcell = "e6"
Case "e6"
 

Excel Facts

Control Word Wrap
Press Alt+Enter to move to a new row in a cell. Lets you control where the words wrap.
another approach
1) protect all the cells except the cells to want to use (A1, E2, E4, etc.)
format-->cells-->protection-->uncheck locked
2) protect the sheet
tools-->protection-->protect sheet

With TAB you can jump to the next cell, with Shift+TAB to the previous cell
 
Upvote 0
Thanks Bruno, I chose not to do this since the cells that I need are not "in order". For example, had I attached more code you would see that it tabs from e4 to e6,e8,b10,g8,b12. It jumps all over the place.
 
Upvote 0

Forum statistics

Threads
1,207,423
Messages
6,078,443
Members
446,338
Latest member
AliB

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