Pop-up calendar problem

jeo

Registered User.
Local time
Today, 13:42
Joined
Dec 26, 2002
Messages
299
I have a form on which I have a little pop-up calendar which once clicked updates a date field on a screen.
I have an After_Update event for this date field, the problem is that even though the date field gets updated with a date selected from a calendar, the After_Update event isn’t triggered, but if I go and change the date without using the pop-up calendar, it works just fine.
Any ideas on how I can make it work with the pop-up calendar?
Thanks.
Here is code for my on-Click even for the calendar pop-up:
Dim strArguments As String

strArguments = Me.Name & ";End1"
DoCmd.OpenForm "frmCalendar", , , , , acDialog, strArguments
 
If:
- FormB is the calendar
- FormA contains the updated control
- tbDate is the name of the updated control
- tbDate has an AfterUpdate event handler...

Then, on FormA:
- Create a new "Public Sub DateHasChanged()"
- Move code from "Private Sub tbDate_AfterUpdate()" to this new Sub
- Call "DateHasChanged" from "Private Sub tbDate_AfterUpdate()"

And on FormB, after updating FormA.tbDate, execute:
Forms!FormA.DateHasChanged
 
Setting the focus to another control [text box or button] after the date field is updated by the calander will trigger the AfterUpdate event of the date field.
 
I advise you to not use the ActiveX calander control. Too many problems with the users PC having missing references to the control.

Check out these custom Access calanders for you can import them right into your database...

Popup Calendar - Version 3

I prefer the authors first calendar because I do not want the fancy three months options. Here is the link to that one... Popup Calendar

You have to be a member [membership is free] of the UtterAccess forum to download the samples from their code archives section of the forum.
 
Thank you for all your posts!
I didn't even think about users missing references to the ActiveX calendars.
Will definetly check out these custom Access calendars!
Thanks!
 

Users who are viewing this thread

Back
Top Bottom