• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

listing all names of worksheets in a workbook and listing the value of cell T6 of each worksheet

Rocky.Paredes

New Member
Hi - I really need some help.

I am trying to develop a macro that will:
listing all names of worksheets in a workbook on a separate worksheet
and list the the value of cell T6 of each worksheet.

The macro below will list the sheet names on a separate workbook but how do I get the contents of cell T6 of each worksheet to appear next to the worksheet name?

You're welcome to disregard the macro below and provide your own.

I really appreciate your help! :) Thank you.

Sub ListWorkSheetNames()
Dim Sheetnames
Sheetnames = Sheets.Count
Sheets.Add
ActiveSheet.Name = “SheetList”
Sheets(”SheetList”).Move after:=Sheets(Sheetnames + 1)
For i = 1 To Sheetnames
Range(”A” & i) = Sheets(i).Name
Next i
End Sub
 
Hi,

as you get the name, you get the cell …
Code:
Sub ListDemo()
    C& = Worksheets.Count
    Worksheets.Add , Worksheets(C)
    ActiveSheet.Name = "SheetList"
 
    For R& = 1 To C
        Cells(R, 1).Value = Worksheets(R).Name
        Cells(R, 2).Value = Worksheets(R).[T6].Value
    Next
End Sub
 
Hi,

as you get the name, you get the cell …
Code:
Sub ListDemo()
    C& = Worksheets.Count
    Worksheets.Add , Worksheets(C)
    ActiveSheet.Name = "SheetList"
 
    For R& = 1 To C
        Cells(R, 1).Value = Worksheets(R).Name
        Cells(R, 2).Value = Worksheets(R).[T6].Value
    Next
End Sub

Hi Marc L. The code works great! Thank you for helping me - I really appreciate it :) You're the man!
 
I know this tread was a long time ago...
But the macro still works.
Does anyone know how to adapt this so it creates a list of hyperlinks to the sheets as well?
 
Back
Top