G
Guest
I am trying to refer to a ProjectID field on a subform, where frmProject is
the main form (header) and frmProjectIssue is the subform (detail).
I'm trying to set the focus back to the ProjectID field if it does not
validate correctly.
I am doing it in the AfterUpdate of the field. I can't do it in the Exit
event cuz that causes it to display my msgBox numerous times while the form
loads and while the form closes. That's what I had before and now I am
trying to fix it.
So, I backed up to AfterUpdate.
Halp.
Discussion:
There is a field called ProjectID in both the main form and the sub form.
(yes, this is because they want to show all related family of projects in
the detail form, whenever any one of the family is asked to display in the
header).
Anyway, I have tried:
Forms!frmProject!frmProjectIssue!ProjectID.SetFocus
and
Forms!frmProjectIssue!ProjectID.SetFocus
I am still confuzed about "!" and ".", even though I have read it numerous
times. Doesn't always seem to work for me.
the main form (header) and frmProjectIssue is the subform (detail).
I'm trying to set the focus back to the ProjectID field if it does not
validate correctly.
I am doing it in the AfterUpdate of the field. I can't do it in the Exit
event cuz that causes it to display my msgBox numerous times while the form
loads and while the form closes. That's what I had before and now I am
trying to fix it.
So, I backed up to AfterUpdate.
Halp.
Discussion:
There is a field called ProjectID in both the main form and the sub form.
(yes, this is because they want to show all related family of projects in
the detail form, whenever any one of the family is asked to display in the
header).
Anyway, I have tried:
Forms!frmProject!frmProjectIssue!ProjectID.SetFocus
and
Forms!frmProjectIssue!ProjectID.SetFocus
I am still confuzed about "!" and ".", even though I have read it numerous
times. Doesn't always seem to work for me.