Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
dminkov
 
Posts: n/a
Default Formula returning the worksheet name


Hi everyone!

Is it possible to write a formula, which returns the name of the
worksheet as a value of the cell?

Waiting for your comments,

Dobrin


--
dminkov
------------------------------------------------------------------------
dminkov's Profile: http://www.excelforum.com/member.php...o&userid=17757
View this thread: http://www.excelforum.com/showthread...hreadid=557305

  #2   Report Post  
Posted to microsoft.public.excel.misc
Bernard Liengme
 
Posts: n/a
Default Formula returning the worksheet name

This UDF will do it

Function MySheet()
Application.Volatile
MySheet = ActiveSheet.Name
End Function

Call it with =mysheet()
best wishes

--
Bernard V Liengme
www.stfx.ca/people/bliengme
remove caps from email

"dminkov" wrote in
message ...

Hi everyone!

Is it possible to write a formula, which returns the name of the
worksheet as a value of the cell?

Waiting for your comments,

Dobrin


--
dminkov
------------------------------------------------------------------------
dminkov's Profile:
http://www.excelforum.com/member.php...o&userid=17757
View this thread: http://www.excelforum.com/showthread...hreadid=557305



  #3   Report Post  
Posted to microsoft.public.excel.misc
Bob Phillips
 
Posts: n/a
Default Formula returning the worksheet name

See http://www.xldynamic.com/source/xld.xlFAQ0002.html

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"dminkov" wrote in
message ...

Hi everyone!

Is it possible to write a formula, which returns the name of the
worksheet as a value of the cell?

Waiting for your comments,

Dobrin


--
dminkov
------------------------------------------------------------------------
dminkov's Profile:

http://www.excelforum.com/member.php...o&userid=17757
View this thread: http://www.excelforum.com/showthread...hreadid=557305



  #4   Report Post  
Posted to microsoft.public.excel.misc
 
Posts: n/a
Default Formula returning the worksheet name

The following formula will return path+filename+worksheet name
=CELL("filename",A1)

So, therefore, you can use this formula to get the worksheet name alone
=MID(CELL("filename",A1),1+FIND("]",CELL("filename",A1)),31)

Note that the 31 value above is because a worksheet name can have a max
length of 31.
These formulas point to cell A1 in the current sheet, but can point to
any cell. Also, it is possible for them to point to cells in other
sheets and the formulas will return those other worksheet names. The
formula can also point to its own cell (i.e. the formula can be in A1
and point to A1).


Bob Phillips wrote:
See http://www.xldynamic.com/source/xld.xlFAQ0002.html

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"dminkov" wrote in
message ...

Hi everyone!

Is it possible to write a formula, which returns the name of the
worksheet as a value of the cell?

Waiting for your comments,

Dobrin


--
dminkov
------------------------------------------------------------------------
dminkov's Profile:

http://www.excelforum.com/member.php...o&userid=17757
View this thread: http://www.excelforum.com/showthread...hreadid=557305


  #5   Report Post  
Posted to microsoft.public.excel.misc
dminkov
 
Posts: n/a
Default Formula returning the worksheet name


The UDF made exactly what I wanted, thank you , Beranrd :)


--
dminkov
------------------------------------------------------------------------
dminkov's Profile: http://www.excelforum.com/member.php...o&userid=17757
View this thread: http://www.excelforum.com/showthread...hreadid=557305

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Lookup Data in two seperate Spreadsheets Padraig Excel Worksheet Functions 6 June 28th 06 03:05 PM
Worksheet from Formula Scott Morton Excel Worksheet Functions 2 June 23rd 06 12:00 PM
Returning a cell's formula in a different cell T.R. Young Excel Worksheet Functions 2 February 16th 06 06:41 PM
What is the formula to reference a cell in a different worksheet? Jenney Zellner Excel Worksheet Functions 2 October 14th 05 09:26 AM
Cannat paste that macro formula onto a worksheet Stephen White Excel Discussion (Misc queries) 2 May 27th 05 11:58 AM


All times are GMT +1. The time now is 07:41 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"