Userdefine function to check the cell is having formula or not:-
Function checkformula(x As Range)
checkformula = x.HasFormula
Suppose if you want to check cell "D1" is having formula or not
You need to type =checkformula(d1)
It will return TRUE if having formula and FALSE if not.