from vbe help
HasFormula Property
See Also Applies To Example Specifics
True if all cells in the range contain formulas; False if none of the cells
in the range contains a formula; Null otherwise. Read-only Variant.
Example
This example prompts the user to select a range on Sheet1. If every cell in
the selected range contains a formula, the example displays a message.
Worksheets("Sheet1").Activate
Set rr = Application.InputBox( _
prompt:="Select a range on this worksheet", _
Type:=8)
If rr.HasFormula = True Then
MsgBox "Every cell in the selection contains a formula"
End If
--
Don Guillett
SalesAid Software
"Phillips" wrote in message
news:q%WIb.251383$_M.1138230@attbi_s54...
I would like to copy the formula from 1 cell to a different cell. I want
to
do this ONLY if there is a formula.
For instance, I might have a formula in column D and F on worksheet "Test"
in each row
I would like to, on worksheet "Test2" to copy the actual formula into a
give
cell. How can I TEST for the presence of a formula, and then how can I
copy
the actual "=function()" to my new cell (preferably with a delimiter
infront
so I can actually see the formula.
Thanks