Calendar and Diary

Visual FoxPro includes a simple calendar and diary accessory. It appears as a separate window and is neither as impressive nor as flexible as the ActiveX calendars such as mscal.ocx. It is however very much simpler to use and does not rely on your users having the correct version of the various external DLLs that are required by the more complex ActiveX solutions. [Calendar]

Using the Calendar

The calendar no longer appears as an option on any of the FoxPro menus. The only way to make it appear is through program code. You can write code to call the calendar from a command button or from a menu option or perhaps froma hot key.

Activate Window 'calendar'

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

_DIARYDATE = {25/12/2006}

then the Calendar will (at least in the UK) display the month of December 2006 with the 25th selected and the events of the 25th visible.

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

[Warning of missing resource file]

Because the Calendar is a window within FoxPro you can use the standard functions to inspect its status. For example:

?WVISIBLE ('calendar')

will return .T. if the Calendar window is visible.

Like the Calculator, the Calendar tool has been available since version 2.00 of FoxPro for DOS.

Access Tips

FoxPro Tips

General Tips

 

Related Items

Alvechurch Data - Microsoft FoxPro and Access Database Development and Training

Alvechurch Data provide training and development support for businesses using Microsoft FoxPro, Visual FoxPro and Access databases.

Read More

Autocomplete in Visual Fox Pro

Autocomplete in Visual Fox Pro

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.

Read More

FoxPro Functions

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

Read More

Development Services

Alvechurch Data have fifteen years experience developing databases for small business use.

Read More

Training Services

Details of the training courses offered by Alvechurch Data.

Read More