View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bernard Liengme Bernard Liengme is offline
external usenet poster
 
Posts: 4,393
Default Function to detect type of cell contents

This user defined function will do the job:
Function Whattype(mycell)
If mycell.HasFormula Then
Whattype = "Formula"
Else
Whattype = "Input"
End If
End Function

Call it with =Whattype(a1)
If you are unfamiliar with VBA see David McRitchie's site on "getting
started" with VBA
http://www.mvps.org/dmcritchie/excel/getstarted.htm
But feel free to return here with more questions , or contact me direct
--
Bernard V Liengme
www.stfx.ca/people/bliengme
remove caps from email

"Mark" wrote in message
et...
Is there a formula or function that I can use that will tell me if a
cell's contents contain plain text or number that is input, or if it is a
formula that is generating the results.

Thanks