Home |
Search |
Today's Posts |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
thanks to all of you.
i have thought it out ,like Mr Edwin Tam suggested to me, i will do better with his advice thanks "Edwin Tam" wrote in message ... I'm not sure what the variable "x" is for in your example. But try this: Function SHEETNAME() As String Dim s As Object Application.Volatile Set s = Application.Caller SHEETNAME = s.Parent.Name End Function You type in a cell: =SHEETNAME() The formula will return the sheetname of the sheet where you typed the formula. Regards, Edwin Tam http://www.vonixx.com "EXCEL NEWS" wrote: here is my function Function SheetName(x) As String ' Application.Volatile SheetName = ActiveSheet.name End Function ' what i want to do is to get the sheet name in in which a cell (like =SheetName(0)) is in. not the. name of ActiveSheet. what should i do. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
what's the function to return a sheetname in a cell in Excel? | Excel Worksheet Functions | |||
Automatically update SheetName in workbook sub if SheetName changes | Excel Discussion (Misc queries) | |||
Does anyone see this .xls]sheetname? | Excel Discussion (Misc queries) | |||
Using a cell to reference sheetname in vlookup function | Excel Worksheet Functions | |||
SheetName | Excel Programming |