ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Excel VBA - using yearfrac function in VBA (https://www.excelbanter.com/excel-programming/303278-excel-vba-using-yearfrac-function-vba.html)

dannyboy[_2_]

Excel VBA - using yearfrac function in VBA
 
Hi
I checked the Analysis ToolPak box and Analysis ToolPak-VBA box in
Add-In dialog box in order to use the yearfrac function in VBA code.
However, I have hard to time to call the function in VBA environment;
in other word, I can not write a VBA program using the yearfrac
function! How can I use the function in VBA?

Thank you for your help

Dan


---
Message posted from http://www.ExcelForum.com/


Chip Pearson

Excel VBA - using yearfrac function in VBA
 
Dan,

You first have to load the Analysis TookPak - VBA add-in, as you
have already done. Then, in the VBA Editor, go to the Tools menu,
choose References, and add a reference to ATPVBAEN.xla. Once
you've done this, you can use the functions in the ATP as if they
were built-in VBA functions.


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com



"dannyboy " wrote in
message ...
Hi
I checked the Analysis ToolPak box and Analysis ToolPak-VBA box

in
Add-In dialog box in order to use the yearfrac function in VBA

code.
However, I have hard to time to call the function in VBA

environment;
in other word, I can not write a VBA program using the yearfrac
function! How can I use the function in VBA?

Thank you for your help

Dan


---
Message posted from http://www.ExcelForum.com/




dannyboy[_3_]

Excel VBA - using yearfrac function in VBA
 
It works!


Thank you very much

dan


---
Message posted from http://www.ExcelForum.com/



All times are GMT +1. The time now is 01:25 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com