Thanks for the help Rob :)
Ken
--- In [email protected], "Rob Kennedy" <[EMAIL PROTECTED]> wrote:
>
> kenhaile wrote:
> > I want to send data and execute methods on an MDIForm from a
> > MDIChild-of-a-MDIChild
>
> MDI children cannot have MDI children of their own.
>
> There can be only one MDI parent form in an application. All MDI
children
> in a program are necessarily children of that one MDI parent.
>
> > WITHOUT having to include the MDIForm in the
> > uses clause of the MDIChild-of-a-MDIChild.
>
> Why?
>
> > For example, how can I do the following:
> >
> > An MDIForm has a method named SetTable. This method stores the name
> > of a table in a public variable named CurrentTable.
> >
> > Another form, MDIChild2, is a descendant of MDIChild1. I'd like to
> > set the variable CurrentTable found in MDIForm from MDIChild2. I know
> > that I can include the MDIForm in the uses clause of MDIChild2. But,
> > I'm curious how to do this using an object-oriented call.
>
> (Application.MainForm as TMDIForm).SetTable(x);
>
> See the objects? That is object oriented.
>
> To do that, you'll need to include the TMDIForm class's unit in one
of the
> calling unit's "uses" clauses.
>
> > MDIChild2 --> MDIChild1 --> MDIForm(CurrentTable)
> >
> > Thanks in advance for your help :)
>
>
> --
> Rob
>