Excel VBA - using yearfrac function in VBA

D

dannyboy

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
 
C

Chip Pearson

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
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top