vb.net controls:
Just create a new code module and declare your public variables there, not
within a subform. Using Public variables is considered "bad form" nowadays,
but in simple applications, and used sparingly, they can be a quick solution
to a problem like yours.
Or, you can save the values to a temporary data file, like an INI or XML,
and each subform could have access to that.
Or, create invisible "holder" controls or properties on the childform that
is the parent of the subforms, and use those to pass values.
Or,..... I'm sure there are lots of other possibilities. A little
googling on passing values between forms couldn't hurt.
GS
"The hardest thing in the world to understand is the income tax." --
Albert Einstein
[quoted text, click to view] "Jerry" <jerry.hancock@gmx.net> wrote in message
news:dc7e5m$sqf$1@online.de...
> Thanks George,
>
> this works they way I imagined it.
>
> However now I have the problem of exchanging variables in the "subforms".
>
> Here's what I have:
> 1 parantform (mdi)
> childform in the parant which is the main form
> and several "subforms" as controls on the childform
>
> Each subform has inputs and calculations that I want to use in one of the
> other subforms. Let's say input subform1
> is x and y. input subform2 is z. How do I calculate x*y*z on subform3?
>
> "public x as" makes it public within the subform, but not in the mainform.
>
>
> Thanks,
>
> Jerry
>