$$Excel-Macros$$ Re: stuck in function

2009-07-13 Thread larry
Thank you for the quick reply. There were several responses saying the same thing- delete (x,t) in the function equation and explaining it is not necessary and obviously confuses the program. I look forward to running the program with the corrected code. On Jul 11, 5:00 am, "Daniel" wrote: > Not

$$Excel-Macros$$ Re: stuck in function

2009-07-11 Thread Daniel
Not sure it's what you want : Public Function C_D(X As Integer, T As Integer) As Variant C_D = Exp(-((X - T) / Sqr(10#)) ^ 2 / 2) / Sqr(20# * _ Application.WorksheetFunction.Pi()) End Function Regards. Daniel > -Message d'origine- > De : excel-macros@googlegroups.com [mailto:excel-

$$Excel-Macros$$ Re: stuck in function

2009-07-11 Thread Vivek Agrawal
hi given below is the correct expression. when you are assigning an expression to the function return value, you don't pass arguments. Public Function C_D(X As Integer, T As Integer) As Variant C_D = Exp(-((X - T) / Sqr(10#)) ^ 2 / 2) / Sqr(20# * Application.WorksheetFunction.Pi()) End Functi

$$Excel-Macros$$ Re: stuck in function

2009-07-11 Thread vivek agrawal
hi given below is the correct expression. when you are assigning an expression to the function return value, you don't pass arguments. *Public Function C_D(X As Integer, T As Integer) As Variant* * * *C_D = Exp(-((X - T) / Sqr(10#)) ^ 2 / 2) / Sqr(20# * Application.WorksheetFunction.Pi())* * * *