Using Excel defined functions in UDF

  • Thread starter Thread starter Matthew.M.Snow
  • Start date Start date
M

Matthew.M.Snow

I'm trying to create a UDF that allows users to input to binomial
experiments and the results will be a p-value for comparing the
proportions.

My function crashes everytime I try to use an excel built in function
like

SQRT(X) or NORMSDIST(X)... etc

SQRT I got around by using (X) ^ 0.5 and I found a formula that got me
close the normdist, but I'd like to use the exact formula in excel

Thanks,
Matt
 
VBA has its own Sqrt functiojn called Sqr.

One way to get at functions that don't work in VBA bnormally is tio use
evaluate, such as

Application.Caller.Parent.Evaluate("SQRT(" & inVal & ")")

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 
Back
Top