Disable certain dates in a calendar in a form (1 Viewer)

youssefalaouia

New member
Local time
Today, 16:05
Joined
Jun 26, 2020
Messages
2
hello everybody,
as you can see I have a table that contains holidays (T_holiday) and a table that contains employees and their busy days. And I have a form that lets the supervisor choose the date on which each employee gets a certain task. The choice is made using a calendar in the form. I want the supervisor not to be able to choose the dates on which there is a holiday or on which the employee already is busy by disabling these dates from the calendar in the form.
 

Attachments

  • Practice File_Custom Calendar Control MS Access.accdb
    520 KB · Views: 42

Gasman

Enthusiastic Amateur
Local time
Today, 15:05
Joined
Sep 21, 2011
Messages
14,411
Do not select the records in the first place.
Criteria should omit those records.
Then any selection is not possible.
 

moke123

AWF VIP
Local time
Today, 10:05
Joined
Jan 11, 2013
Messages
3,935
I get a dictionary of the dates to exclude and then when looping through the controls do a test to see if the date is in the dictionary and disable the control if true.
 

youssefalaouia

New member
Local time
Today, 16:05
Joined
Jun 26, 2020
Messages
2
I get a dictionary of the dates to exclude and then when looping through the controls do a test to see if the date is in the dictionary and disable the control if true.
What i wish to know is how to disable the control?
 

Users who are viewing this thread

Top Bottom