+ Reply to Thread
Results 1 to 3 of 3

referencing a sheet name?

Hybrid View

zerosleep referencing a sheet name? 12-02-2008, 04:02 PM
dominicb Good evening zerosleep ... 12-02-2008, 04:27 PM
zerosleep Thanks DominicB, works... 12-03-2008, 11:45 AM
  1. #1
    Registered User
    Join Date
    12-29-2004
    Posts
    37

    referencing a sheet name?

    looking for a formula that will get me the sheet name...
    example:
    I have 3 sheets each named X, Y, Z
    in cells A1 I want the name of sheet 3, which would be X

    thanks for the help!
    Last edited by zerosleep; 12-03-2008 at 11:53 AM.

  2. #2
    Forum Expert dominicb's Avatar
    Join Date
    01-25-2005
    Location
    Lancashire, England
    MS-Off Ver
    MS Office 2000, 2003, 2007 & 2016 365
    Posts
    4,867

    Smile

    Good evening zerosleep
    Quote Originally Posted by zerosleep View Post
    I have 3 sheets each named X, Y, Z
    in cells A1 I want the name of sheet 3, which would be X
    There are ways and means of extracting the sheetname, but only (I think) the activesheet. There is also a drawback that the file must be saved.

    Why not use a custome function :
    Function SheetName(WhichSheet As Integer)
    Application.Volatile
    SheetName = Sheets(WhichSheet).Name
    End Function
    In this instance using the formula :
    =SheetName(3)
    would return X.

    HTH

    DominicB
    Please familiarise yourself with the rules before posting. You can find them here.

  3. #3
    Registered User
    Join Date
    12-29-2004
    Posts
    37
    Thanks DominicB, works great!! much appreciated!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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