There are two example programs provided for JCalendar. The two programs are similar except one uses the JCalendar component and the other uses the JCalendarCombo component.

View the Example1 program. View the Example2 program.

If you download the FLib source, you can use Ant to build and run the example programs:

cd JCalendar
ant runExample1
ant runExample2

Four calendars appear in each example. The upper-left calendar is used to select a date and time. Today's date is displayed at the bottom of the calendar. In Example2, it is the only one of the four combo box calendars which is editable.

The upper-right calendar selects just a date. The lower-left calendar selects just a time.

The lower-right calendar uses the French locale (all the others use the default locale). Because the JCalendar component takes advantage of the localization in the Calendar class, we get a French-version of the Gregorian calendar. The month and weekday names are in French. The week starts on a Monday. The time uses a 24-hour clock.

The JCalendar package is not completely localized for French. For instance, the tool tips on the calendar buttons appear in English. See the tutorial for instructions on fully localizing the package.

When you run either example, each date selection will be echoed to the window from which you ran the ant command.