Bill Golden
asked on
Problem when combining two working formulas into a single cell
I combined the following two formulas,
=MID(CELL("filename"),SEAR CH("[",CEL L("filenam e"))+5,SEA RCH("]",CE LL("filena me"))-SEAR CH("[",CEL L("filenam e"))-14)
and
=MID(CELL("filename",A1),F IND("]",CE LL("filena me",A1))+1 ,255)
I combined the two formulas as follows
=MID(CELL("filename"),FIND ("[",CELL( "filename" ))+5,FIND( "]",CELL(" filename") )-FIND("[" ,CELL("fil ename"))-1 4)&MID(CELL("filename"),FIND( "]",CELL(" filename") )+1,255)
into one cell. The first formula pulls part of the FileName into the cell. The second formula pulls the TabName into the cell. Each work appropriately in individual cells. But when you combine them, the second formula displays the TabName at opening until some action causes calculation, then the number is updated. This is not the case when the formula is in a cell by itself.
I am not sure, but I suspect it has something to do with the SEARCH command being used in the first formula versus the FIND command being used in the second formulas.
=MID(CELL("filename"),SEAR
and
=MID(CELL("filename",A1),F
I combined the two formulas as follows
=MID(CELL("filename"),FIND
into one cell. The first formula pulls part of the FileName into the cell. The second formula pulls the TabName into the cell. Each work appropriately in individual cells. But when you combine them, the second formula displays the TabName at opening until some action causes calculation, then the number is updated. This is not the case when the formula is in a cell by itself.
I am not sure, but I suspect it has something to do with the SEARCH command being used in the first formula versus the FIND command being used in the second formulas.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Initially the formula works fine. But does not work when changing from one tab to the other tab. The oddity in the +15 -4 is that we do not want the entire filename. The filename portion works fine because obviously it does not change. The entire problem is that each tab is named separately and as you switch from one tab to the other the cell retains the name of the tab that was active when the file was first opened. After you click two or three cells on the worksheet, the cell containing the tabname updates itself.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Alas, I was using a slightly different iteration of the formula in what I was testing versus what I thought I was using. Next time, I will check the formulas a little closer. Thanks, learning!
»bp