About MDI App

  • Thread starter Thread starter George Varelas
  • Start date Start date
G

George Varelas

Could someone tell me how can I set a property on a control which locates in
the parent form from within a child form. The application MDI application.

In particular I want to set the "text" of the status bar of the main (parent
form) to something when the child form works and reset when the work is
over. The status bar of the parent form is public.

I don't know how can I reach controls they are contained in the parent form
in an MDI application.
 
Hello,

George Varelas said:
Could someone tell me how can I set a property on
a control which locates in the parent form from within a
child form. The application MDI application.

In particular I want to set the "text" of the status bar
of the main (parent form) to something when the child
form works and reset when the work is
over. The status bar of the parent form is public.

In the child:

\\\
DirectCast(Me.MdiParent, MainForm).StatusBar1.<property> = <value>
///

HTH,
Herfried K. Wagner
 
I am very sorry I forgot to mention that the language is "C#"
Anyway thank you.
 
Hello,

George Varelas said:
I am very sorry I forgot to mention that the language is "C#"
Anyway thank you.

\\\
((MainForm)this.MdiParent).StatusBar1.<property> = <value>
///

HTH,
Herfried K. Wagner
 
Hi.
It did not work. The word "MainForm" is unknown for the compiler and it can
not perform the cast.
 
Hello,

George Varelas said:
It did not work. The word "MainForm" is unknown for
the compiler and it can not perform the cast.

Replace "MainForm" with the class name of your MDI container form.

HTH,
Herfried K. Wagner
 
It worked.

Thank you

Herfried K. Wagner said:
Hello,



Replace "MainForm" with the class name of your MDI container form.

HTH,
Herfried K. Wagner
 

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

Back
Top