View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Lori Lori is offline
external usenet poster
 
Posts: 340
Default how to use GETFORMULA() in EXCEL 2003?

It's possible to pass references to these functions in a worksheet
formula using the following technique. With A1 selected define the name
Ref as:

Ref: =TEXTREF("if("&MID(GET.FORMULA(!A1),6,250))

Then use the syntax =IF(1,Function,Reference) in a formula.
So to find the formula in A1 define the name get.formula as below and
enter in any cell:

=IF(1,get.formula,A1)

get.formula: =GET.CELL(6,Ref)

This also recalculates whenever A1 changes.

Herbert Seidenberg wrote:

I am assuming you mean GET.FORMULA()
Assume a cell named Profit contains this formula:
=($A$6*$C$4)+$B$8
Define an arbitrary name PF_text
Insert Name Define PF_text
Refers To: =GET.FORMULA(Profit)
When you enter this into a cell:
=PF_text
you will get this text
=(R6C1*R4C3)+R8C2
Probably not what you want since it is in R1C1 style.
To get a result in A1 reference style, use this instead:
Insert Name Define PC_text
Refers To: =GET.CELL(6,Profit)
=PC_text will get you this text:
=($A$6*$C$4)+$B$8
If you use names instead of cell references in Profit,
either function will give you the same results.