You must have come across a number of situations when you were trying to explain a formula that you have written in Excel and the result of the formula. This kind of situation basically demands both the formula expression and the formula result to be displayed simultaneously. For example, from the below screenshot, if you are trying to explain that the formula in cell G2 is =TODAY() and that this is a built-in function in Excel that returns today’s date, you might instruct to view the result in the cell (active cell in the below screenshot) and to view the formula contained in the active cell from the formula bar (highlighted in rounded box in below screenshot).
what if I you want to see both formula and the result of the formula side by side or one below the other and avoid viewing two extreme corners of the window? Excel offers a new function named FORMULATEXT to address this purpose. FORMULATEXT function takes only mandatory argument referring the address of the cell containing formula that you wish to view. It returns the formula contained in the cell whose address is passed as the only argument to it. In our example, if you enter the formula =FORMULATEXT(B2) in cell F2, it returns the value as =TODAY() as in the below screenshot. Now the formula used in cell G2 and the value returned by it are just side by side making it easier to understand the formula and explain it to others too.
A nifty handy formula for people like me Happy Excel Learning..!!
New function in Excel 2016 to display in a cell, the formula contained in another cell