Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Reminder for end of the month
Message
From
14/07/2007 08:32:52
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01240440
Message ID:
01240441
Views:
11
This message has been marked as the solution to the initial question of the thread.
>How to make a reminder end of the month.I want to reminder for the users, When the last date of current month.
>thanks

First, you must decide with what event to invoke this. If the program runs continuously, you might use a Timer object. If it is shut down at night, you might use application startup.

You may also want to save information somewhere, that the reminder was given. This is to avoid repetition, since the user may do the startup more than once during a single day.

To calculate if a certain day is the end of the month, there are probably several ways. Here is one: just test if

month(date()+ 1) # month(date())

Or, if you already have some sort of scheduler application, and want to generate dates for every month of the year (to save future "events" in a table):
* For year 2007
for lnMonth = 1 to 12
  ldDate = gomonth(date(2007, lnMonth, 1), 1) - 1
  * Save information here
next
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform