views:

91

answers:

1

Similar question was posed, (didn't understand it)

the field.value in one sub-form, how do copy it to to to a field.value in another sub-form with a simple copy and paste button

Thank you

A: 

Say you have a main form with two subforms, the first named SubForm1 and the second SubForm2. You want to copy the value in the control txtSource on SubForm1 to txtDestination on SubForm@. The VBA code for that would be:

  Me!SubForm2.Form!txtDestination = Me!SubForm1.Form!txtSource

You'd execute that line of code in the OnClick() event of a command button on the main form that contains the subforms.

David-W-Fenton