Calendar and Diary


FoxPro includes a simple calendar or diary tool. It appears as a separate window and is not as impressive as ActiveX calendars such as mscal.ocx. It is however much simpler to use and does not rely on your users having the correct version of various external DLLs. [Calendar]

Using the Calendar

Displaying the calendar is a simple matter of making its window visible:

Activate Window 'calendar'

The date selected by the user is stored in the _DIARYDATE system variable. You can read and write to this variable whether or not the Calculator window is visible. If you write to _DIARYDATE:

_DIARYDATE = {25/12/2006}

then the Calendar will (at least in England) display the month of December 2006 with the 25th selected.

The notes for each day are stored in the Data field of the FoxUser table. The Calendar will still work without the resource file but an unpleasant warning message is displayed before the calendar appears.

[Warning of missing resource file]

Like the Calculator , the Calendar tool has been available in FoxPro since version 2.00.


Hints & tips

The textbox class in Visual FoxPro 9 has a new Autocomplete property which shows the user the previous values that have been entered in that textbox.
Autocomplete in VFP 9

Your Access database will look more impressive if you add custom toolbars...
Custom toolbars

FoxPro has always had functions to read and write files at a low level...
Foxpro low level file functions

More...
More pages of hints and tips for users of Microsoft FoxPro and Access databases.

Site Map