Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

HELP VBA DOESN'T WORK

Status
Not open for further replies.

Aran10

Vendor
Mar 17, 2011
6
GB
I copied and pasted this Vba into access with my tables
I then made a query with the following functions

The date due expressions can then be calculated by:
- Creating a provisional date due field and using this expression:
Provisional Date Due: DateAdd("d",13,[Loan Date])
- Then create the Date Due field with this expression:
Date Due: NextWorkDay([Provisional Date Due])

SCENARIO
A book can be on loan for fourteen days. The due date is the Loan date plus fourteen days. If the Due date falls on a day when the school is closed (e.g. during a holiday period) then the Due date becomes the date that is after the holidays


I have the tables tblholidays and field holidate with each individual date that is a holiday but I get an error with the nextworkday function and it turns up yellow? The holidate field is date/time

How can I correct this?

UPDATE:

I HAVE ATTACHED MY ACCESS DATABASE, PLZ COPY AND PASTE THE MODULE VBA: THEN RUN THE QUERY BUT IT DOESNT WORK, PLZ UPDATE THE DATABASE AND GIVE ME THE LINK OR HELP ME AS I CANNOT SOLVE THIS PROBLE
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top