Search code examples
vbaexcelexcel-formulaexcel-2007

Show formula with values instead of reference in EXCEL


I have similar problem as described in this topic: Show formula of a cell, but values instead of references

But I need to show as in

as in this picture

formulas directly in excel sheet. Thanks for answers in advance!


Solution

  • Using @SiddharthRout Function... First; Place the Function as a module in your workbook. Under the Developers Tab, select Insert_Module, Copy and paste the Function. Second; Save the below sub in the Project window in your ThisWorkbook folder...

    Sub ShowFormulValues()
    Dim lRow As Long
    lRow = Sheet1.Cells(Rows.Count, 1).End(xlUp).Row
    
        Range("B1:B" & lRow).Formula = "=ConvertToValues(A1)"
    End Sub
    

    Run ShowFormulValues and Sid's Formula will provide the information you want.