View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
TUNGANA KURMA RAJU
 
Posts: n/a
Default Printing formulas

Thanks,Bob.It also worked well,once again I am greatful to you.

"Bob Phillips" wrote:

You could just dump them all to a new worksheet and print that

Sub PrintFormulas()
Dim cell As Range
Dim sh As Worksheet
Dim i As Long

On Error Resume Next
Set sh = Worksheets("Formulas")
On Error GoTo 0
If sh Is Nothing Then
Set sh = Worksheets.Add
sh.Name = "Formulas"
Else
sh.Cells.ClearContents
End If
For Each cell In ActiveSheet.UsedRange
If cell.HasFormula Then
i = i + 1
sh.Cells(i, "A").Value = cell.Address(False, False)
sh.Cells(i, "B").Value = "'" & cell.Formula
End If
Next cell
sh.Activate
sh.Columns("B:B").AutoFit
End Sub


--

HTH

RP
(remove nothere from the email address if mailing direct)


"TUNGANA KURMA RAJU" wrote in
message ...
I have 5 work sheets in a BOOK,each sheet a2:m30, every cell contains
formula.Iwould like to keep a hard copy of these formulas I have used.In
Toolsoptionsview tab I have checked formulas,but these formulas wrap

each
other by which I can't print these formulas.Is there any way to print all
these formulas at one go.