Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Modules / DAO / VBA / March 2005

Tip: Looking for answers? Try searching our database.

Natural Log Function ( LN )

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Kit Truong - 02 Mar 2005 16:57 GMT
Hello,

I'm using Access 2000 and I'm trying to use the natural logarithm function
( ln ) in one of my modules but one doesn't exist.

Does anyone know or have a function that uses the existing Math.log/exp
functions to get the equivalent ln function?

Thanks.
Ken Snell [MVP] - 02 Mar 2005 17:19 GMT
VBA's Log function is the natural logarithm.

From ACCESS Help File:

Log Function
     Returns a Double specifying the natural logarithm of a number.

Syntax
   Log(number)

The required number argument is a Double or any valid numeric expression
greater than zero.

Remarks
   The natural logarithm is the logarithm to the base e. The constant e is
approximately 2.718282.
   You can calculate base-n logarithms for any number x by dividing the
natural logarithm of x by the natural logarithm of n as follows:
           Logn(x) = Log(x) / Log(n)

   The following example illustrates a custom Function that calculates
base-10 logarithms:
           Static Function Log10(X)
               Log10 = Log(X) / Log(10#)
           End Function

Signature

       Ken Snell
<MS ACCESS MVP>

> Hello,
>
[quoted text clipped - 5 lines]
>
> Thanks.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.