Finding formulas

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Do you have a formula or something that I can use in
conditional format to tell if a cell contains a formula.
 
-----Original Message-----
Do you have a formula or something that I can use in
conditional format to tell if a cell contains a formula.
.
You could use this macro

Sub test()
Selection.SpecialCells(xlFormulas).Select
With Selection.Interior
.ColorIndex = 6
.Pattern = xlSolid
End With
Range("A1").Activate
End Sub


Peter Atherton
 
Copy/paste this UDF to a general module in your workbook.

Function IsFormula(cell)
Application.Volatile
IsFormula = cell.HasFormula
End Function


CF>Formula is: =IsFormula(A1)

Pick a Pattern from the Format button.

Gord Dibben Excel MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top