G
Guest
I am tring to display data on a second form based on a selected value in the
first form.
Open FORM works fine (this code is run from the first form):
DoCmd.OpenForm "Form2", acNormal
[Forms]![Form2].TextBox2.Value = "100"
TextBox2 value in used in a WHERE clause (within a command button on the
second form (form2) that also works fine when clicked).
The problem is, TextBox2 value is NULL (or default value) up until the
form is displayed so the code that uses this value returns no records.
(Unless I click on the button after form is displayed).
OPEN, LOAD, RESIZE, ACTIVATE, CURRENT all retun NULL. (Enter and GotFocus
events don't execute)
Does any one know at which FORM's event, value of a Control, which has
been updated from another FORM, becomes available? So, I can run code
against it!
Thank you in advance.
M.Afzal
first form.
Open FORM works fine (this code is run from the first form):
DoCmd.OpenForm "Form2", acNormal
[Forms]![Form2].TextBox2.Value = "100"
TextBox2 value in used in a WHERE clause (within a command button on the
second form (form2) that also works fine when clicked).
The problem is, TextBox2 value is NULL (or default value) up until the
form is displayed so the code that uses this value returns no records.
(Unless I click on the button after form is displayed).
OPEN, LOAD, RESIZE, ACTIVATE, CURRENT all retun NULL. (Enter and GotFocus
events don't execute)
Does any one know at which FORM's event, value of a Control, which has
been updated from another FORM, becomes available? So, I can run code
against it!
Thank you in advance.
M.Afzal