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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Creating future appointment schedule 1

Status
Not open for further replies.

Abby4

Technical User
Jan 2, 2008
1
CA
I am a beginner and need help to create appointment schedules for clients. Some clients need appointment weekly while others need monthly appointments. Can access generate a table of dates in the future based on start and end dates?
 
The short answer is yes.
Don't know exactly what you're looking for, but here's a routine to create some future dates based on today + some number of days. Perhaps it will assist or give some idea of what you might do.

Date is an Access function representing today's Date.
This routine adds days to today's date to get a series of future dates. It adds 0, then 14, then 28...up to 140

Successive dates should be 2 weeks apart.

Code:
Sub test1()
Debug.Print " Date Now "; " DaysToAdd " & " FutureDate"
Dim futureDate As Date
For i = 0 To 140 Step 14
    futureDate = Date + i
    Debug.Print Date & "   " & i & "      " & futureDate
Next i
End Sub
 
Every time someone want to build an appointment application in Access I have to ask why do this in Access. If you have Access I assume you have Outlook, so why not use Outlook? Even a good programmer can not code the functionality that Outlook gives you.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top