Results 1 to 4 of 4
Like Tree1Likes
  • 1 Post By pbornemeier

excel 2010 how to set tab/return order

This is a discussion on excel 2010 how to set tab/return order within the Excel Questions forums, part of the Question Forums category; I am new to this forum and in my first post don;t think I was specific enough. So I will ...

  1. #1
    New Member
    Join Date
    Feb 2012
    Posts
    10

    Default excel 2010 how to set tab/return order

    I am new to this forum and in my first post don;t think I was specific enough. So I will try to explain what exactly I am trying to do and hopefully someone can help.
    1. I have saved my file in excel as a xlsm file.
    2. I have tried a macro code someone gave me in an earlier post but I don't I explain what I needed and will try to do better.
    3. Do I need to delete the worksheet macro/code and if so how do I do that.
    4. I am working in xcel 2010 and need to do the following.
    5. want to set the tab and return key to a particular order
    6. Not every cell will require something be inputted every time
    7. Need the tab/return key to go through the same order regardless if something is enter in a cell or not.
    8. Here is the beginning order I need to follow..I won;t list all them buthere are the first few and if someone can help me with this I would be so thankful!

    I need to finish before work tomorrow and have spent way to much time on it but has to be done.

    List of cell order. "C1, J1, Q1, C3, B5, C6, C7, L5, L6, L7, L8, L9, L10, O5, O6, O7, O8, O9, O10, D15, D15, M13, R13, etc.."

    This is a form I have created and want a person to be able to go through it using the tab or return key in a certain order but the person doesn;t have to input something in a cell if they don't need to.

    Please help. I would even be willing to email someone the worksheet if that would be easier.

    Thanks is advance.

  2. #2
    Board Regular pbornemeier's Avatar
    Join Date
    May 2005
    Location
    Virginia Beach, VA USA
    Posts
    2,544

    Default Re: excel 2010 how to set tab/return order

    This line of code will select the specified cells:
    Code:
    range("C1, J1, Q1, C3, B5, C6, C7, L5, L6, L7, L8, L9, L10, O5, O6, O7, O8, O9, O10, D15, D15, M13, R13").Select
    It could be set to execute when the worksheet becomes active, or by a button on the Quick Access Toolbar or a shortcut key (or any or all of the above)

    Using the Tab or Enter key will cycle through those cells in the specified order.
    Shift+Tab will move backwards through the list/

    If any other cell is selected with the mouse then the Tab/Enter keys won't automatically go to a desired cell, so it would be best to unlock the cells in the select statement and then protect the sheet so only unlocked cells may be selected.

    The last link in my sig describes how to add the code to your workbook.
    Last edited by pbornemeier; Feb 21st, 2012 at 09:15 AM.
    Phil

    - Use CODE tags to keep your code formatted. See: BB Tags
    - How to attach Screenshots
    - Try searching for your answer first, see how
    - Test and validate results for all code on a copy of your worksheet!! How do you use the code you just found?
    - Posting guidelines, forum rules and terms of use
    - Read the FAQs

  3. #3
    New Member
    Join Date
    Feb 2012
    Posts
    10

    Default Re: excel 2010 how to set tab/return order

    Are you telling me that the file cannot be saved with a tab order? What is the code to enter to save it with the tab order? I can activate to have it changed but need the file to remain in the tab order so when I email to someone they don't have to activate the macro or anything besides just atb through.

  4. #4
    Board Regular pbornemeier's Avatar
    Join Date
    May 2005
    Location
    Virginia Beach, VA USA
    Posts
    2,544

    Default Re: excel 2010 how to set tab/return order

    Right-click on the worksheet tab and select View Code

    Paste the following code into that codepage:
    Code:
    Private Sub Worksheet_Activate()
        Range("C1, J1, Q1, C3, B5, C6, C7, L5, L6, L7, L8, L9, L10, O5, O6, O7, O8, O9, O10, D15, D15, M13, R13").Select
    End Sub
    The cells will be selected (with the first cell in the list as the active cell) each time the worksheet becomes the active worksheet.

    You should also unprotect those cells and lock the worksheet to keep other cells from being selected if the rest of your worksheet will allow it to be configured that way.

    To keep the user from being asked to enable macros each time the workbook is open, the code will have to be placed in a trusted location, or the directory where the code will be stored will have to be added to the trusted location list. Check out Office Button | Excel Options | Trust Center to read about how to do this.
    teachman likes this.
    Phil

    - Use CODE tags to keep your code formatted. See: BB Tags
    - How to attach Screenshots
    - Try searching for your answer first, see how
    - Test and validate results for all code on a copy of your worksheet!! How do you use the code you just found?
    - Posting guidelines, forum rules and terms of use
    - Read the FAQs

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


DMCA.com