standing order code for a banking program (1 Viewer)

Happy YN

Registered User.
Local time
Today, 06:17
Joined
Jan 27, 2002
Messages
425
My db records payments made out of various accounts.
I would like to be able to provide the user with an interface that would allow him to enter a begin & end date and specify an interval- monthly,anually etc and the code would whip thru that period and insert a record for each month/ year.
Has anyone done anything similar?
How do you cope with a user who wants it done on the last day of each month?
Any other issues?
Thanks
 

Uncle Gizmo

Nifty Access Guy
Staff member
Local time
Today, 06:17
Joined
Jul 9, 2003
Messages
11,481
>>>> last day of each month? <<<<

I have seen code posted for calculating first day of month, last day of month etc, so I would have a search of the forum for this.

As an extra piece of information, I did read a good tip somewhere, to find the last day of the month, which is difficult as some months are 31 days some 30 and one 28 or 29! That was: find the first day of the next month and take one day off.
 

Bat17

Registered User.
Local time
Today, 06:17
Joined
Sep 24, 2004
Messages
1,687
Uncle Gizmo said:
..find the last day of the month, which is difficult as some months are 31 days some 30 and one 28 or 29! That was: find the first day of the next month and take one day off.
finding last day of month can also be done by using 0 as the day in date serial, which will then find last day of month before, so
DateSerial(2005, 11, 0) = 31/10/2005

But for banking you are going to need something more complicated to find the last Banking day in the month which will allow for weekends and public holidays

Peter
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Top Bottom