Date Pickers, Calendar Controls, and Calendar resources

MajP

You've got your good things, and you've got mine.
Local time
Yesterday, 21:32
Joined
May 21, 2018
Messages
9,362
There has been some recent interest in a replacement for the MS calendar control that existed prior to 2010. I have been collecting date pickers, calendar controls, and calendars for a long time and thought it would be a good idea to have one thread with lots of good examples. Some of these are mine, but many are not. I will add links and other examples as I get them and feel free to post examples and links. In my mind there are three different things but often just get called "calendar control", so that can be confusing. For the purpose of this thread I would like to use the terminology

1. Date Picker: This is a pop up that returns a date to a control and defaults to the value in the control
2. Calendar Control: Same function as a date picker but resides on the form
3. Calendar: Allows you to put information in a day and display it. This require more than just a form because you have to have the underlying table to save information.

Example of a Date Picker from @isladogs

DatePicker Isladogs.jpg


Example of a Calendar Control. In this case the same form can be used as a pop up date picker or reside in the form as a Calendar Control

DatePicerAndCC.jpg


Calendar

Simple one month Calendar
Simple Calendar.jpg


Here is the most complicated calendar I have built. It is a one year view that allow you to display different codes in different colors and even multiple colors in a single day. See 1 Feb.


YearView.jpg
 

Attachments

Last edited:
Calendars

From @Gasman

The Peter Hibbs calendar below is a full "outlook like" calendar application.
 

Attachments

Last edited:
Some of them I provided are listed in this thread, but I have not looked at all of them.

Here is a good calendar
 
FWIW, I thought I'd add one that I have. Includes a Calendar, a DatePicker, and a TimePicker.

The Calendar is a simple Event Calendar - Date, Event Description, and Time.
Uses a dictionary object so requires a reference to MS Scripting Runtime.
cal.jpg

calDetail.jpg


The date picker is a custom class

dp.jpg


The TimePicker is a custom class.
The simulated spinner control can be customized as to the minute increments.
The default is 5 mins.

tp.jpg
 

Attachments

Last edited:
This statement is NOT intended to downplay the efforts of ANYONE who has built their own calendaring system. A thousand requirements could exist that force you to use one of these excellent solutions to keep things as "pure Access." And I fully understand that such requirements could exist. Business is funny like that.

We cannot forget, however, that if you have Access, you probably have other parts of Office. IF you have Outlook, the "calendar" wheel (including shareable calendars and future-dated task reminders) has already been invented. Regarding MajP's categories, this statement does not apply to Date Pickers or Calendar Controls, only to full-functional scheduling calendars that are more than just a simple (or complex) control.

When considering cost to implement at a site and complexity to maintain, the Outlook calendar isn't that hard to use, is readily shareable, and is easy to control via VBA code as an app object to update it with tasks requiring reminders, tasks requiring ToDo list entries, etc. Further, if you work for a government agency, they might actually bar use of code that doesn't come from a company that will stick around to maintain it. Some government regulations say that you can't buy someone else's code if there is no customer service department associated with the vendor.

All I am saying here is that if tech difficulty or code support requirements are a factor in your solution, don't ignore off-the-shelf items like Outlook. If you need an all-Access solution and don't face software support issues, the offerings from the various people here are definitely things to consider. They are all highly competent people.
 
Last edited:
Great effort and thanks.
It helped me implement the Isladog Date Picker which suits best in my scenario.
 
As you chose to use my Better Date Picker, you might want to look at the latest release version which has several enhancements


Although it works well, the code is far from optimal. At some point the entire app will be rewritten using class module code
 
I changed mine over to a class a while back . I actually have 3 classes but it eliminated hundreds of lines of code.
I use a wrapper to handle the buttons for the calendar grid. I also stole some of your code to position the datepicker on the form.
 

Attachments

Perhaps I'll steal your class code!
I've been intending to convert mine for years to eliminate hundreds of lines of repetitive code
However it works and is a popular download so its been a case of if it ain't broke don't fix it. . .
 
Often you want a way to pick just a month of a give year. Example you want to generate a financial report for a given month. A calendar control can work and you just disregard the day portion, but that may not be intuitive. This allows you to define the range of the useable years. It returns the first of the month which you can use directly or split into month and year parts.
YearMonth.png
 

Attachments

As you chose to use my Better Date Picker, you might want to look at the latest release version which has several enhancements



Although it works well, the code is far from optimal. At some point the entire app will be rewritten using class module code

The way I work with my dynamical forms is I think in line with class module code, but without the formal declarations.
On of my first attempts, some 20 years ago, was a calender form, and is still actual. It is still based on a predefined form, with the controls "on their place".
It is activated by a DblClick on any Date-control. If that control is not null, than that date is displayd, else Date is used.
It can inline toggle between Monday or Sunday as start of the week, and I am working now to adept the day/month names to almost any language.

Schermopname (114).png


Nice feature is the repeating arrow keys.
UP and DOWN move the "red" day to the previous or next week. When this day is part of a different month, the month is refreshed.
LEFT and RIGHT move the "red" day to the previous or next day. Also here, when the day is part of a different month, the month is refreshed.
A button "Feestdagen" opens a form with the variable dates of e.g. Easter, Ascension, etc., for the current year, or more years.

The OK-button is only visible if the original Date-control is editable.
 
@Imb, The purpose of this thread is to post resources for others to use. No one cares about your "dynamic" form, unless you are going to post your calendar control as a resource. It provides zero value to this thread and is just wasting space and other people's time. This is meant to provide other's people useable resources not to pontify about a design construct.
Please delete your post in this thread, and you can repost it in your thread where it would be more appropriate as you advertise your "dynamic forms."
Or you can provide some kind of useable resource in this thread and then leave the above post it. Thanks.
 
Last edited:

Users who are viewing this thread

Back
Top Bottom