+ Reply to Thread
Results 1 to 5 of 5

Add INDEX PAGE to a workbook - Selected worksheets, not all from left to right

  1. #1
    Registered User
    Join Date
    12-21-2018
    Location
    RI, USA
    MS-Off Ver
    Office 365
    Posts
    26

    Cool Add INDEX PAGE to a workbook - Selected worksheets, not all from left to right

    I'm familiar with the adding of an "Index" worksheet as the 1st on the left of many worksheets in a workbook and was able to find the following online: (added as right-click -> View Code)

    Private Sub Worksheet_Activate()
    Dim wSheet As Worksheet
    Dim M As Long
    M = 1
    With Me
    .Columns(1).ClearContents
    .Cells(1, 1) = "INDEX"
    .Cells(1, 1).Name = "Index"
    End With

    For Each wSheet In Worksheets
    If wSheet.Name <> Me.Name Then
    M = M + 1
    With wSheet
    .Range("H1").Name = "Start" & wSheet.Index
    .Hyperlinks.Add Anchor:=.Range("H1"), Address:="", SubAddress:="Index", TextToDisplay:="Back to Index"
    End With
    Me.Hyperlinks.Add Anchor:=Me.Cells(M, 1), Address:="", SubAddress:="Start" & wSheet.Index, TextToDisplay:=wSheet.Name
    End If
    Next wSheet
    End Sub


    I could use a suggestion on how to best use similar functionality but I'd like to place the newly-added INDEX worksheet as the 5th or 6th worksheet in my file
    In other words, I'd like to only include all worksheets RIGHT of the INDEX, but exclude the 1st several tabs from being part of the refreshed Index results.

    Any thoughts or assistance is very much appreciated.

    Dave

  2. #2
    Forum Guru
    Join Date
    07-25-2011
    Location
    Florida
    MS-Off Ver
    Excel 2003
    Posts
    9,643

    Re: Add INDEX PAGE to a workbook - Selected worksheets, not all from left to right

    Change this...
    Please Login or Register  to view this content.
    To this...
    Please Login or Register  to view this content.
    Surround your VBA code with CODE tags e.g.;
    [CODE]your VBA code here[/CODE]
    The # button in the forum editor will apply CODE tags around your selected text.

  3. #3
    Registered User
    Join Date
    12-21-2018
    Location
    RI, USA
    MS-Off Ver
    Office 365
    Posts
    26

    Re: Add INDEX PAGE to a workbook - Selected worksheets, not all from left to right

    AlphaFrog: Thank you for the prompt reply. I'm continuing to learn, and certainly do appreciate the knowledge share. Will test in the AM and let you know my findings (looks like a simple one). Dave

  4. #4
    Registered User
    Join Date
    12-21-2018
    Location
    RI, USA
    MS-Off Ver
    Office 365
    Posts
    26

    Re: Add INDEX PAGE to a workbook - Selected worksheets, not all from left to right

    Excellent Results! Thank you again Alpha

  5. #5
    Registered User
    Join Date
    12-21-2018
    Location
    RI, USA
    MS-Off Ver
    Office 365
    Posts
    26

    Re: Add INDEX PAGE to a workbook - Selected worksheets, not all from left to right

    Success. Should I note this as solved? Or is that something you might do? Thank you. Dave

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. I need one workbook page to feed selected data to others!
    By Rich19041980 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 05-26-2015, 09:10 AM
  2. Lost several columns on left of the workbook page
    By ambdavid in forum For Other Platforms(Mac, Google Docs, Mobile OS etc)
    Replies: 3
    Last Post: 05-04-2015, 06:09 PM
  3. Hot to automatically change selected index on the web page (geteElemntById)
    By junior_88 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-12-2015, 02:29 PM
  4. [SOLVED] Creating a Summary Page of Selected Data Lines from multiple worksheets in same workbook
    By MrNightly in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 01-15-2014, 01:07 PM
  5. adding and removing page breaks from selected worksheets
    By debraannhall in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-16-2012, 04:06 PM
  6. Index page numbers on worksheets
    By rm7302 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-03-2010, 10:26 AM
  7. [SOLVED] Excel Page Setup on selected worksheets
    By Agustus in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-09-2006, 05:45 PM

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1