Tab Control Subform

  • Thread starter Thread starter Con Giacomini
  • Start date Start date
C

Con Giacomini

I have a tab control form which includes a subform. When I add a new record
I need to copy a field from the main form to the subform, but so far without
success.

The first page of the main form includes a field named [Open Date]. In the
control source of a field called OpenDate on the subform I use the
expression =[Forms]![Add/Edit Cases]![Open Date].

I have also used this expression as a default value in the subform field,
but that doesn't work either.

Interestingly, when I select an existing case from the main form's combo box
the OpenDate field on the subform correctly enters the value from the main
form's [Open Date].

Any ideas would be appreciated.
 
Con said:
I have a tab control form which includes a subform. When I add a new
record I need to copy a field from the main form to the subform, but
so far without success.

The first page of the main form includes a field named [Open Date].
In the control source of a field called OpenDate on the subform I use
the expression =[Forms]![Add/Edit Cases]![Open Date].

I have also used this expression as a default value in the subform
field, but that doesn't work either.

Interestingly, when I select an existing case from the main form's
combo box the OpenDate field on the subform correctly enters the
value from the main form's [Open Date].

Any ideas would be appreciated.

That is what the MasterLink and ChildLink properties of the subform control are
for. Set those and this is all handled automatically.
 
Back
Top