Hi,
I'm using access 2003. I have a textbox called txtdate on the main form and when I click this textbox I have a calendar pop up and users can select which date they want it to be appear on this textbox.
I also have a subform called child181 that the source object is coming form a query called InOut. This subform will show all the in and out inventories.
What I want is when user select the date from the calendar, I want the subform to automatically requery and shows all the in and out inventory for that date.
Here is my code on the txtdate
I did the same thing to the gotfocus event, but somehow it won't requery unless I click another field on the main form. Could someone please help me...???
Thank you...
I'm using access 2003. I have a textbox called txtdate on the main form and when I click this textbox I have a calendar pop up and users can select which date they want it to be appear on this textbox.
I also have a subform called child181 that the source object is coming form a query called InOut. This subform will show all the in and out inventories.
What I want is when user select the date from the calendar, I want the subform to automatically requery and shows all the in and out inventory for that date.
Here is my code on the txtdate
Code:
Private Sub txtDate_Click() Calendar7.Visible = True If Not IsNull(txtDate) Then Calendar7.Value = txtDate.Value Else Calendar7 = DateValue(Now()) End If End Sub
Code:
Private Sub txtDate_AfterUpdate() Calendar7 = txtDate Me.txtDate.SetFocus Forms!supervisor!Child181.Requery End Sub
Thank you...
Comment