ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Tab variable (https://www.excelbanter.com/excel-worksheet-functions/171446-tab-variable.html)

SF

Tab variable
 
Hi,

I have 12 worksheets represent each month of the year. In every worksheet, I
have a label or header showing "Monthly Sale of XXXX". I try to combine
string with the [Tab] hoping to replace the XXXX with the name of the
Worksheet, but I am not able to acheive that.

Could the NG suggest something?

SF



Max

Tab variable
 
One way ..

Click Insert Name Define
Put under "Names in workbook:": WSN
Put in the "Refers to:" box:
=MID(CELL("Filename",INDIRECT("A1")),FIND("]",CELL("Filename",INDIRECT("A1")
))+1,32)
Click OK

The above defines WSN as a name we can use to refer to the sheetname in
formulas. It will auto-extract the sheetname implicitly (file must be saved
beforehand). Technique came from a post by Harlan.

Then you could use in any sheet, in any cell:
="Monthly Sale of "&WSN
to return the desired results
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"SF" wrote:
I have 12 worksheets represent each month of the year. In every worksheet, I
have a label or header showing "Monthly Sale of XXXX". I try to combine
string with the [Tab] hoping to replace the XXXX with the name of the
Worksheet, but I am not able to acheive that.

Could the NG suggest something?

SF




All times are GMT +1. The time now is 09:35 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com