AfterUdate event issue

B

Bdavis

I'm using a calendar module to update a date field, [datelast], on form.

This works great... the problem is for some reason, it it does not trigger
the AfterUpdate event. I have sever proceedures that are activated by that
event. The work fine if I just type in a new date.

I have found that I can put the code in the LostFocus event and that works
but it is not ideal.

Any ideas? I've pasted my calendat field update code below... one of you
probably wrote it.

Private Sub DateLast_DblClick(Cancel As Integer)
Dim blRet As Boolean
Dim dtStart As Date, dtEnd As Date

dtStart = Nz(Me.DateLast.Value, 0)
dtEnd = 0

blRet = ShowMonthCalendar(mc, dtStart, dtEnd)
If blRet = True Then
Me.DateLast = dtStart
Else
' Add any message here if you want to
' inform the user that no date was selected
End If
' Me.Period.SetFocus

End Sub
 
D

Douglas J. Steele

Simply put a call to the routine in your code:

Call DateLast_AfterUpdate()
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top