This code will list all the formulas in the selection in the Immediate Window.
Dim rCell As Range
If TypeName(Selection) = “Range” Then
For Each rCell In Selection.Cells
Debug.Print String(4, ” “) & rCell.Address(0, 0), rCell.Formula
If you have a range selected, it loops through each cell. Then it prints four spaces, the cell’s address ((0,0) means relative, e.g. A1 not $A$1), and the cell’s formula. Note that if a cell contains a value instead of a formula, the Formula property returns the value. I wonder why that is.
Why the four spaces? So I can paste into SuperUser and it thinks it’s code.