Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Can you add a excel funtion into access?? 1

Status
Not open for further replies.

redsand23

Technical User
Feb 22, 2002
77
US
Here is my challenge. I need to use the normsinv function from excel in my access report to report sigma values. Is there a way to add in this function to access?

Thanks for any help!!!
 
Hi!

Someone answered this recently in tek-tips though I cannot remember who. The basic steps you need to take are:

1. In the code window select Tools/References and check the reference to Microsoft Excel.

2. In a module create a Public Function:

Public Function fnNormsInv(prob As Double, mean As Double, stddev As Double) As Double

Dim xlApp As New.ExcelApp

fnNormsInv = xlApp.Application.WorksheetFunction.normsinv(prob, mean, stddev)

Set xlApp = Nothing

End Function

You may need to open a workbook instead of an excel app but you can play with that.

3. Call the function from anywhere in your DB, including SQL and pass the function the appropriate parameters.

hth
Jeff Bridgham
bridgham@purdue.edu
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top