That's the same question we've been discussing. Because the
main form is initialized before any subforms, you can not
reliably "pass" values (of any kind) to a subform until all
the subforms have been initialized. That's why I keep
saying that the subform's should "pull" the values from the
mainform.
The important point here is that Public **variables** in a
form module are properties of the form object and can be
referenced as I indicated earlier.
If you are using the word "variable" only loosely and mean
something other than a VBA variable in a module, then try to
explain more about what you are really trying to accomplish.
--
Marsh
MVP [MS Access]
On the same issue, is it possible to use variables on the main form and
pass
the values to the sub-forms? Would this simply be declaring them public on
the main form?
"Marshall Barton" wrote