How to Use Financial Function "ACCRINT" in VBA

A

Atif Akbar

Hi,

I have configured the following addins
Analysis Toolpak
Analysis Toolpak-VBA
But still i am able to access few financial functions using the
following :

VBA.Financial....

I want to use ACCRINT function in Macro
Can anybody help
 
P

Patrick Molloy

If you're using VBA then you only need the VBA add-in.
In the IDE I assume that you've set a reference to the
atpvbaen.xls add-in?
If so, then open the object browser, select this in the
object list then you'll see all the available 'members'
ie properties and methods. Selecting Accrint will show
you the required parameters.
Accrued interest is the compensation if you will that the
buyer of a bond pays to then seller for the propertion of
interest that the seller earned.

For example suppose a bond pays 6% per annum interset and
this is paid every six months. Thus for a $10,000 bond,
the six monthly amount is $300 ( 1/2 * 6% * 10000 )

Lets assume payment is 1st January and 1st July. Lets
look at the case where the holder of the bond decides to
sell it, and payment date is say 1st March. We would
argue that th eseller owned the bond for two out of the
six month period. The buyer will on 1st July receive the
full coupon for the six month period, even though the
will only have owned th ebond for four months. Thus, when
the buyer pays for the bond, he will pay th eseller the
price PLUS two month of accrued interest.

The Accint function allows you to calculate this value.
The "key" variables are the frequency and th ebasis,
because these will be different in different markets. For
example, US domestic bonds pay semi annual on a 30 day
month, 360 day year. UK bonds pay semi annual on an
actual day ( ie 356/366) day year. Eurobonds are annual
pay on 30/360 and so on.

Patrick Molloy
Microsoft Excel MVP



-----Original Message-----

Hi,

I have configured the following addins
Analysis Toolpak
Analysis Toolpak-VBA
But still i am able to access few financial functions using the
following :

VBA.Financial....

I want to use ACCRINT function in Macro
Can anybody help


------------------------------------------------

~~View and post usenet messages directly from http://www.ExcelForum.com/

~~Now Available: Financial Statements.xls, a step by
step guide to creating financial statements
 
B

Bill Manville

Atif said:
I want to use ACCRINT function in Macro
In the VB editor create a Tools / Reference to atpvbaen.xls
Then you can just use Accrint like any other built-in function.

Bill Manville
MVP - Microsoft Excel, Oxford, England
No email replies please - reply in newsgroup
 

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