Best way to Call method on MDI Parent from MDI child (vb.net 2005)

E

Eric

I want to call a method on the MDI parent from the child. Basically the
method will set some text (message) on a status strip and show the
appropriate icon (for the type of message).

I'd also like to put a progress bar on the MDI parent and
activate/manipulate it by the child

What's the best way to do this?

TIA

Eric
 
G

Guest

Eric,

The child form has a reference to the parent in its MDIParent property. Use
the reference to call methods, etc on the parent.

For example, assume that Form1 is the MDI parent. Here is code on the child
that calls a method named ShowMessage on the parent:

Dim f As Form1
f = Me.MdiParent
f.ShowMessage()

Kerry Moorman
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top