If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Inserting DAYS360 formula
hi
I have three field lastdate activedate count I have a field "average" which i require to calculate the number of days: e.g. average = days360 (lastdate, activedate, false) how can i use this formula and that the result should be stored in the "average" field. kindly help Reg Deepak |
#2
|
|||
|
|||
Inserting DAYS360 formula
Days360 is an Excel function, not an Access one. You can set a reference to
Excel and use it by wrapping it up as an Access function something like this: Function XL360(Arg1, Arg2) As Double Dim objXL As New Excel.Application XL360= objXL.WorksheetFunction.Days360(Arg1,Arg2) Set objXL = Nothing End Sub Now you can use it like this: XL360("1/1/2004", "12/31/2004") which should return 360 -- Arvin Meyer, MCP, MVP Microsoft Access Free Access downloads: http://www.datastrat.com http://www.mvps.org/access "Deepak" wrote in message ... hi I have three field lastdate activedate count I have a field "average" which i require to calculate the number of days: e.g. average = days360 (lastdate, activedate, false) how can i use this formula and that the result should be stored in the "average" field. kindly help Reg Deepak |
Thread Tools | |
Display Modes | |
|
|